From e698ed6c57deaec35b23180df9c43d185f5d9fa4 Mon Sep 17 00:00:00 2001 From: cesnimda Date: Tue, 20 Oct 2026 20:50:34 +0200 Subject: [PATCH] test(cv): retain localized template entitlement coverage --- job-tracker-ui/e2e/cv-settings-presentation.spec.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/job-tracker-ui/e2e/cv-settings-presentation.spec.ts b/job-tracker-ui/e2e/cv-settings-presentation.spec.ts index 6f9ea71..fe91fdc 100644 --- a/job-tracker-ui/e2e/cv-settings-presentation.spec.ts +++ b/job-tracker-ui/e2e/cv-settings-presentation.spec.ts @@ -151,11 +151,11 @@ for (const [mode, language, premium] of [['light', 'en', false], ['dark', 'nb', await scan(page, info, 'phone-advanced'); await page.setViewportSize({ width: 1440, height: 900 }); await page.getByRole('tab', { name: t.cvEditorTemplate, exact: true }).click(); await page.getByRole('button', { name: t.cvEditorAllTemplates, exact: true }).click(); - const technical = page.getByRole('button', { name: 'Technical', exact: true }); await expect(technical).toHaveAttribute('aria-disabled', premium ? 'false' : 'true'); + const technical = page.getByRole('button', { name: t.cvTemplateTechnicalName, exact: true }); await expect(technical).toHaveAttribute('aria-disabled', premium ? 'false' : 'true'); await expect(technical).toHaveAccessibleDescription(new RegExp(premium ? t.cvEditorProUnlocked : t.cvEditorPro)); if (!premium) { await technical.click({ force: true }); await technical.focus(); await page.keyboard.press('Enter'); expect((await read()).settings.themeId).toBe('minimal'); await expect(page.getByRole('dialog')).toHaveCount(0); } await capture(page, info, 'templates'); await scan(page, info, 'templates'); - const target = premium ? technical : page.getByRole('button', { name: 'Code', exact: true }); + const target = premium ? technical : page.getByRole('button', { name: t.cvTemplateCodeName, exact: true }); await target.focus(); await page.keyboard.press('Enter'); const dialog = page.getByRole('dialog', { name: t.cvEditorChangeTemplateTitle }); await expect(dialog).toBeVisible(); await capture(page, info, 'reset-confirmation'); await page.keyboard.press('Escape'); await expect(target).toBeFocused(); expect((await read()).settings.themeId).toBe('minimal');