Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 6 additions & 21 deletions tests/e2e/support-care.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,38 +8,23 @@ function localePath(locale: (typeof locales)[number], path: string = '') {

test.describe('Support Care Pages', () => {
for (const locale of locales) {
test(`loads support care page correctly for ${locale}`, async ({ page }) => {
test(`loads support care page correctly for ${locale}`, async ({
page,
}) => {
await page.goto(localePath(locale, 'support-care'));

// Page should load successfully
await expect(page).toHaveURL(/\/support-care/);

// Should have main content
await expect(page.locator('main')).toBeVisible();

// Should maintain locale in URL
if (locale === 'de') {
await expect(page).toHaveURL(/\/de\/support-care/);
} else {
await expect(page).toHaveURL(/^(?!.*\/de\/).*\/support-care/);
}
});

test(`loads support care maven page correctly for ${locale}`, async ({ page }) => {
await page.goto(localePath(locale, 'support-care-maven'));

// Page should load successfully
await expect(page).toHaveURL(/\/support-care-maven/);

// Should have main content
await expect(page.locator('main')).toBeVisible();

// Should maintain locale in URL
if (locale === 'de') {
await expect(page).toHaveURL(/\/de\/support-care-maven/);
} else {
await expect(page).toHaveURL(/^(?!.*\/de\/).*\/support-care-maven/);
}
});
}
});
Loading