Skip to content

to.have.text(undefined) does not break the tests #216

Open
@vanpacheco

Description

@vanpacheco

I am not sure whether this is an issue, but I do think this behavior is inconvenient. For instance, the following test passes:

it('has text', () => {
  const test = shallow(<span>Test</span>);
  expect(test).to.have.text(undefined);
});

I'd appreciate any light you shed on why this is happening or on whether this is an issue at all.

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