Skip to content

Commit

Permalink
Fix flaky test (#4987)
Browse files Browse the repository at this point in the history
  • Loading branch information
obulat authored Sep 25, 2024
1 parent 8c27991 commit 684c0dd
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions frontend/test/playwright/e2e/search-navigation.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,12 +65,13 @@ test.describe("search history navigation", () => {
}) => {
await goToSearchTerm(page, "galah")
await (await getContentLink(page, IMAGE)).click()
await page.waitForURL(/\/search\/image\?/)

// There are no content links on single media type search pages
await expect(await getContentLink(page, IMAGE)).toBeHidden()
expect(page.url()).toContain("/search/image")

await page.goBack({ waitUntil: "networkidle" })
await page.goBack()
await page.waitForURL(/\/search\?q=galah/)

await expect(await getContentLink(page, IMAGE)).toBeVisible()
await expect(await getContentLink(page, AUDIO)).toBeVisible()
Expand Down

0 comments on commit 684c0dd

Please sign in to comment.