Skip to content

Commit 9215847

Browse files
committed
Improve failing test
1 parent ad93bf0 commit 9215847

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

playwright/e2e/home.spec.ts

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -137,10 +137,13 @@ test.describe("Homepage", () => {
137137
await page.click('div[class="slider-slide slide-visible slide-current"]')
138138

139139
// wait for page load
140-
await page.waitForNavigation()
140+
await page.waitForURL("**/explore/campaigns/")
141141

142-
// Check if the URL includes "/explore/campaigns" and the header has the expected text
143-
expect(page.url()).toContain("/explore/campaigns")
142+
// check if Explore campaigns page was loaded with some region filter enabled
143+
const regionFilterChip = await page.textContent(
144+
"[data-cy=filter-chip]"
145+
)
146+
expect(regionFilterChip).toContain("region: ")
144147
})
145148
})
146149
})

0 commit comments

Comments
 (0)