Skip to content

Commit 1bc73b7

Browse files
Update docs.
1 parent b26c9fe commit 1bc73b7

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

website/docs/matchers/Array.mdx

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,17 @@ Use `.toIncludeAllMembers` when checking if an `Array` contains all of the same
3737
});`}
3838
</TestFile>
3939

40+
### .toIncludeAllMembersInOrder([members])
41+
42+
Use `.toIncludeAllMembersInOrder` when checking if an `Array` contains all of the same members of a given ordered set in the same order.
43+
44+
<TestFile name="toIncludeAllMembersInOrder">
45+
{`test('passes when given array values match the members and order of the ordered set', () => {
46+
expect([1, 2, 3]).toIncludeAllMembers([1, 2, 3]);
47+
expect([{ foo: 'bar', }, { baz: 'qux' }]).toIncludeAllMembersInOrder([{ foo: 'bar' }, { baz: 'qux' }]);
48+
});`}
49+
</TestFile>
50+
4051
### .toIncludeAllPartialMembers([members])
4152

4253
Use `.toIncludeAllPartialMembers` when checking if an `Array` contains all of the same partial members of a given set.

0 commit comments

Comments
 (0)