Skip to content

Commit

Permalink
Increase waitFor timeout for useImage hook tests
Browse files Browse the repository at this point in the history
  • Loading branch information
louise-davies committed Nov 3, 2023
1 parent a93e87b commit a87925c
Showing 1 changed file with 18 additions and 9 deletions.
27 changes: 18 additions & 9 deletions src/api/images.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,12 @@ describe('images api functions', () => {
wrapper: hooksWrapperWithProviders(),
});

await waitFor(() => {
expect(result.current.isSuccess).toBeTruthy();
});
await waitFor(
() => {
expect(result.current.isSuccess).toBeTruthy();
},
{ timeout: 5000 }
);

const request = await pendingRequest;

Expand All @@ -42,9 +45,12 @@ describe('images api functions', () => {
wrapper: hooksWrapperWithProviders(),
});

await waitFor(() => {
expect(result.current.isSuccess).toBeTruthy();
});
await waitFor(
() => {
expect(result.current.isSuccess).toBeTruthy();
},
{ timeout: 5000 }
);

const request = await pendingRequest;

Expand All @@ -69,9 +75,12 @@ describe('images api functions', () => {
}
);

await waitFor(() => {
expect(result.current.isSuccess).toBeTruthy();
});
await waitFor(
() => {
expect(result.current.isSuccess).toBeTruthy();
},
{ timeout: 5000 }
);

const request = await pendingRequest;

Expand Down

0 comments on commit a87925c

Please sign in to comment.