You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/api/expect.md
+7-1Lines changed: 7 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -422,14 +422,20 @@ test('structurally the same, but semantically different', () => {
422
422
423
423
-**Type:**`(received: string) => Awaitable<void>`
424
424
425
-
`toContain` asserts if the actual value is in an array. `toContain` can also check whether a string is a substring of another string.
425
+
`toContain` asserts if the actual value is in an array. `toContain` can also check whether a string is a substring of another string. Since Vitest 1.0, if you are running tests in a browser-like environment, this assertion can also check if class is contained in a `classList`, or an element is inside another one.
0 commit comments