Skip to content

Commit

Permalink
improve done function
Browse files Browse the repository at this point in the history
  • Loading branch information
kahirokunn committed Oct 3, 2020
1 parent e5c217b commit 380726e
Showing 1 changed file with 2 additions and 3 deletions.
Expand Up @@ -11,10 +11,9 @@ function snapshotTest({ item, asyncJest, framework, testMethod, testMethodParams
it(
name,
() =>
new Promise((done, reject) =>
new Promise((resolve, reject) =>
testMethod({
done,
reject,
done: (error: any) => (error ? reject(error) : resolve()),
story: item,
context,
...testMethodParams,
Expand Down

0 comments on commit 380726e

Please sign in to comment.