File tree Expand file tree Collapse file tree 6 files changed +18
-12
lines changed Expand file tree Collapse file tree 6 files changed +18
-12
lines changed Original file line number Diff line number Diff line change @@ -16,8 +16,8 @@ list help::
16
16
@echo " <PRE-COMMIT>"
17
17
@echo " setup-pre-commit: Sets up pre-commit (assuming it is installed)"
18
18
@echo " <PLAYWRIGHT TESTS>"
19
- @echo " tests: Runs playwright against the old theme."
20
- @echo " tests-update-screenshots: Runs playwright against the old theme."
19
+ @echo " tests: Runs playwright against the new theme."
20
+ @echo " tests-update-screenshots: Runs playwright against the new theme."
21
21
22
22
.PHONY : biome-format biome-lint biome-all setup-pre-commit tests build-example-site
23
23
FLAG :=
Original file line number Diff line number Diff line change 43
43
{{ partial "lucide" (dict "context" . "icon" "chevron-down") }}
44
44
</ span >
45
45
</ button >
46
- < div class ="dropdown-content " id ="dropdown-content " data-testid ="header__f5sites_content ">
46
+ < div class ="dropdown-content " id ="dropdown-content " data-testid ="header__f5sites__content ">
47
47
< ul >
48
48
{{ range $f5Sites }}
49
49
< li >
Original file line number Diff line number Diff line change @@ -14,7 +14,8 @@ export default defineConfig({
14
14
screenshots : 'only-on-failure' ,
15
15
video : 'retain-on-failure' ,
16
16
trace : 'on-first-retry' ,
17
- timezoneId : 'America/Los_Angeles' ,
17
+ geolocation : { longitude : - 8.486316 , latitude : 51.896893 } ,
18
+ permissions : [ 'geolocation' ] ,
18
19
} ,
19
20
projects : [
20
21
{
Original file line number Diff line number Diff line change @@ -46,7 +46,7 @@ test.describe('Smoke test for header', () => {
46
46
test ( 'F5 Sites button works' , async ( { page } ) => {
47
47
const f5SitesButton = await page . getByTestId ( 'header__f5sites__button' ) ;
48
48
await f5SitesButton . click ( ) ;
49
- const f5SitesContent = await page . getByTestId ( 'header__f5sites_content ' ) ;
49
+ const f5SitesContent = await page . getByTestId ( 'header__f5sites__content ' ) ;
50
50
await expect ( f5SitesContent . count ( ) ) . toBeTruthy ( ) ;
51
51
} ) ;
52
52
} ) ;
Original file line number Diff line number Diff line change @@ -40,6 +40,10 @@ async function openPage(page, sidebarPage) {
40
40
}
41
41
42
42
test . describe ( 'Smoke test for sidebar' , ( ) => {
43
+
44
+ // Slow test
45
+ test . setTimeout ( 100_000 ) ;
46
+
43
47
test . beforeEach ( async ( { page } ) => {
44
48
await page . goto ( '/test-product/' ) ;
45
49
} ) ;
Original file line number Diff line number Diff line change @@ -12,13 +12,14 @@ export async function runSmokeTestOnPage(page) {
12
12
13
13
// THE GDPR Consent button appears when test is run from EU locations. This handles that popup.
14
14
export async function handleConsentPopup ( page ) {
15
- const consentContent = page . locator ( '#truste-consent-content' ) ;
16
- const isConsentContentVisibile = await consentContent . isVisible ( ) ;
17
- if ( isConsentContentVisibile ) {
18
- const consentButton = page . locator ( '#truste-consent-required' ) ;
19
- expect ( consentButton ) . toBeVisible ( ) ;
20
- await consentButton . click ( ) ;
21
- }
15
+ await page . addLocatorHandler (
16
+ page . locator ( '#truste-consent-content' ) ,
17
+ async ( ) => {
18
+ const consentButton = page . locator ( '#truste-consent-required' ) ;
19
+ expect ( consentButton ) . toBeVisible ( ) ;
20
+ await consentButton . click ( ) ;
21
+ }
22
+ ) ;
22
23
}
23
24
24
25
const sleep = ( ms ) => new Promise ( ( r ) => setTimeout ( r , ms ) ) ;
You can’t perform that action at this time.
0 commit comments