to be defined
- <any> [not] to be defined
Asserts that the value is defined.
expect('Hello world!', 'to be defined');expect({ foo: { bar: 'baz' } }, 'to be defined');
This assertion can be negated using the not
flag:
expect(undefined, 'not to be defined');
In case of a failing expectation you get the following output:
expect(undefined, 'to be defined');
expected undefined to be defined