Skip to content

Glossary: Testing Web Apps

expect.objectContaining

Also written: expect.stringContaining

A Vitest helper that matches any object with at least the listed properties, such as method: "POST", ignoring the rest.

Where the book teaches it

Related terms

toMatchObject