Skip to content

Commit

Permalink
fix: E2E search tests
Browse files Browse the repository at this point in the history
  • Loading branch information
bprusinowski committed Nov 4, 2022
1 parent b0fb6e7 commit f159b4d
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions e2e/search.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ test("should be possible to open a search URL, and search state should be recove
);
});

test("search results count coherence", async ({ page, screen, selectors }) => {
test("search results count coherence", async ({ page, selectors }) => {
test.slow();

const categories = [
Expand Down Expand Up @@ -55,7 +55,9 @@ test("search results count coherence", async ({ page, screen, selectors }) => {
const count = await countChip.textContent();
await panelLeft.locator(`:text("${t}")`).click();

await page.locator(`:text("${count} results")`).waitFor({ timeout: 10000 });
await page
.locator(`:text("${count} datasets")`)
.waitFor({ timeout: 10000 });
}
});

Expand All @@ -67,9 +69,7 @@ test("sort order", async ({ page, selectors, screen, actions }) => {

expect(await getSelectValue(select)).toBe("CREATED_DESC");

const searchInput = screen.getAllByPlaceholderText(
"Name, description, organization, theme, keyword"
);
const searchInput = screen.getAllByPlaceholderText("Search");

// Search something, order should be score
await searchInput.type("NFI");
Expand Down

0 comments on commit f159b4d

Please sign in to comment.