Skip to content

Commit

Permalink
💚 Address some test flakiness
Browse files Browse the repository at this point in the history
  • Loading branch information
sergei-maertens committed Nov 22, 2023
1 parent 3d4e5cb commit c92f723
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/components/ComponentConfiguration.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -837,6 +837,11 @@ export const FileUpload: Story = {
});
await expect(canvas.queryByText('.pdf')).toBeVisible();
await userEvent.click(canvas.getByText('.jpg'));
// wait for dropdown to close and selected option to be visible;
await waitFor(async () => {
await expect(canvas.queryByText('.pdf')).toBeNull();
});
await expect(canvas.queryByText('.jpg')).toBeVisible();
});

await step('Submit configuration', async () => {
Expand Down

0 comments on commit c92f723

Please sign in to comment.