test: Add debounce to tests

Extra await with longer time out was added to a test to accomodate searchTerm debounce.
This commit is contained in:
regexowl 2024-04-25 11:11:18 +02:00 committed by Lucas Garfield
parent b80d0fa3ae
commit 45be93db11

View file

@ -323,6 +323,16 @@ describe('Step Packages', () => {
await clearSearchBox();
await typeIntoSearchBox('mock');
// wait for debounce
await waitFor(
() => {
expect(screen.getByText(/mockPkg/)).toBeInTheDocument();
},
{
timeout: 1500,
}
);
await userEvent.click(checkboxes[0]);
await userEvent.click(checkboxes[1]);