Skip to content

Commit b6ded77

Browse files
committed
Less strict test
1 parent af52ec3 commit b6ded77

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/react-async/src/specs.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -283,7 +283,7 @@ export const withPromiseFn = (Async, abortCtrl) => () => {
283283
expect(promiseFn).toHaveBeenCalledTimes(1)
284284
fireEvent.click(getByText("reload"))
285285
expect(promiseFn).toHaveBeenCalledTimes(2)
286-
expect(abortCtrl.abort).toHaveBeenCalledTimes(1)
286+
expect(abortCtrl.abort).toHaveBeenCalled()
287287
})
288288

289289
test("re-runs the promise with new props when the value of `watch` changes", () => {
@@ -404,7 +404,7 @@ export const withPromiseFn = (Async, abortCtrl) => () => {
404404
rerender(<Async onResolve={onResolve} />)
405405
await sleep(10)
406406
expect(onResolve).not.toHaveBeenCalled()
407-
expect(abortCtrl.abort).toHaveBeenCalledTimes(1)
407+
expect(abortCtrl.abort).toHaveBeenCalled()
408408
})
409409

410410
test("does not run `promiseFn` on mount when `initialValue` is provided", async () => {

0 commit comments

Comments
 (0)