Skip to content

TypeError: to.have.style is not a functionΒ #224

@filipenatanael

Description

@filipenatanael

Hello Everyone,

So I'm getting the below error message when trying to run the tests.

expect(wrapper).to.have.style('background-color').equal('#ccc');

  • TypeError: (0 , _chai.expect)(...).to.have.style is not a function"

But when I write the code as below, everything works correctly.

expect(wrapper.props().style.backgroundColor).to.be.equal('#ccc');

Any of yours have gone through this before?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions