Skip to content

Commit

Permalink
[Cloud Security] Fix configurations integration test error (elastic#1…
Browse files Browse the repository at this point in the history
…87017)

## Summary

It fixes elastic#187015 

This PR fixes integration test error by wrapping the expect with the
`waitFor` after the loading results.
  • Loading branch information
opauloh authored Jun 26, 2024
1 parent ace2996 commit e4b1f02
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ describe('<Findings />', () => {
// loading findings
await waitFor(() => expect(screen.getByText(/loading results/i)).toBeInTheDocument());

expect(screen.getByText(/2 findings/i)).toBeInTheDocument();
await waitFor(() => expect(screen.getByText(/2 findings/i)).toBeInTheDocument());

expect(screen.getByText(finding1.resource.name)).toBeInTheDocument();
expect(screen.getByText(finding1.resource.id)).toBeInTheDocument();
Expand Down

0 comments on commit e4b1f02

Please sign in to comment.