Skip to content

Commit

Permalink
fix: add missing types for toPartiallyContain (jest-community#392)
Browse files Browse the repository at this point in the history
  • Loading branch information
idan-at authored Dec 9, 2021
1 parent 5083e49 commit 52bad37
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,12 @@ declare namespace jest {
*/
toIncludeSameMembers<E = any>(members: E[]): R;

/**
* Use `.toPartiallyContain` when checking if any array value matches the partial member.
* @param {*} member
*/
toPartiallyContain<E = any>(member: E): R;

/**
* Use `.toSatisfyAll` when you want to use a custom matcher by supplying a predicate function that returns a `Boolean` for all values in an array.
* @param {Function} predicate
Expand Down Expand Up @@ -494,6 +500,12 @@ declare namespace jest {
*/
toIncludeSameMembers<E = any>(members: E[]): any;

/**
* Use `.toPartiallyContain` when checking if any array value matches the partial member.
* @param {*} member
*/
toPartiallyContain<E = any>(member: E): any;

/**
* Use `.toSatisfyAll` when you want to use a custom matcher by supplying a predicate function that returns a `Boolean` for all values in an array.
* @param {Function} predicate
Expand Down

0 comments on commit 52bad37

Please sign in to comment.