diff --git a/projects/demo-playwright/tests/core/breakpoint-service/breakpoint-service.pw.spec.ts b/projects/demo-playwright/tests/core/breakpoint-service/breakpoint-service.pw.spec.ts index fe209d6d194a..868fe07d0028 100644 --- a/projects/demo-playwright/tests/core/breakpoint-service/breakpoint-service.pw.spec.ts +++ b/projects/demo-playwright/tests/core/breakpoint-service/breakpoint-service.pw.spec.ts @@ -22,7 +22,7 @@ test.describe('Breakpoint service', () => { await tuiGoto(page, DemoRoute.BreakpointService); const example = new TuiDocumentationPagePO(page).getExample('#basic'); - await expect(example).toHaveScreenshot(`breakpoint_${width}x${height}.png`); + await expect(example).toHaveScreenshot(`breakpoint-${width}x${height}.png`); }); }); }); diff --git a/projects/demo-playwright/tests/core/dialogs/dialogs.pw.spec.ts b/projects/demo-playwright/tests/core/dialogs/dialogs.pw.spec.ts index 769f773b6b0b..96ba9cbaf029 100644 --- a/projects/demo-playwright/tests/core/dialogs/dialogs.pw.spec.ts +++ b/projects/demo-playwright/tests/core/dialogs/dialogs.pw.spec.ts @@ -21,7 +21,7 @@ test.describe('Dialogs', () => { await documentationPagePO.apiPageExample.locator('button').click(); await documentationPagePO.prepareBeforeScreenshot(); - await expect(page).toHaveScreenshot(`01-prompt_${width}x${height}.png`); + await expect(page).toHaveScreenshot(`01-prompt-${width}x${height}.png`); }); test.describe(`${width}x${height}`, () => { @@ -39,13 +39,13 @@ test.describe('Dialogs', () => { await documentationPagePO.prepareBeforeScreenshot(); await expect(page).toHaveScreenshot( - `02-dialogs-level-1_${width}x${height}.png`, + `02-dialogs-level-1-${width}x${height}.png`, ); await page.locator('tui-dialog button').nth(1).click(); await expect(page).toHaveScreenshot( - `02-dialogs-level-2_${width}x${height}.png`, + `02-dialogs-level-2-${width}x${height}.png`, ); }); @@ -58,7 +58,7 @@ test.describe('Dialogs', () => { await documentationPagePO.prepareBeforeScreenshot(); await expect(page).toHaveScreenshot( - `03-mobile-dialog_${width}x${height}.png`, + `03-mobile-dialog-${width}x${height}.png`, ); }); @@ -71,7 +71,7 @@ test.describe('Dialogs', () => { await documentationPagePO.prepareBeforeScreenshot(); await expect(page).toHaveScreenshot( - `04-dialogs-dialog-directive_${width}x${height}.png`, + `04-dialogs-dialog-directive-${width}x${height}.png`, ); }); @@ -84,7 +84,7 @@ test.describe('Dialogs', () => { await documentationPagePO.prepareBeforeScreenshot(); await expect(page).toHaveScreenshot( - `05-default-button_${width}x${height}.png`, + `05-default-button-${width}x${height}.png`, ); }); @@ -97,7 +97,7 @@ test.describe('Dialogs', () => { await documentationPagePO.prepareBeforeScreenshot(); await expect(page).toHaveScreenshot( - `06-custom-button_${width}x${height}.png`, + `06-custom-button-${width}x${height}.png`, ); }); @@ -113,7 +113,7 @@ test.describe('Dialogs', () => { test('Prompt', async ({page}) => { await expect(page).toHaveScreenshot( - `07-prompt_${width}x${height}.png`, + `07-prompt-${width}x${height}.png`, ); }); @@ -128,7 +128,7 @@ test.describe('Dialogs', () => { await page.locator('tui-dialog .t-close').click(); await expect(page).toHaveScreenshot( - `08-prompt-confirm_${width}x${height}.png`, + `08-prompt-confirm-${width}x${height}.png`, ); }); diff --git a/projects/demo-playwright/tests/core/hint/hint.pw.spec.ts b/projects/demo-playwright/tests/core/hint/hint.pw.spec.ts index 1cb585dfb07f..7c6cb215183d 100644 --- a/projects/demo-playwright/tests/core/hint/hint.pw.spec.ts +++ b/projects/demo-playwright/tests/core/hint/hint.pw.spec.ts @@ -43,7 +43,7 @@ test.describe('TuiHint', () => { await new TuiDocumentationPagePO(page).prepareBeforeScreenshot(); await expect(page).toHaveScreenshot( - `02-hint-manual-direction-${directionIndex}__${direction}-and-width__${width}.png`, + `02-hint-manual-direction-${directionIndex}-${direction}-and-width-${width}.png`, ); }); }); @@ -80,19 +80,19 @@ test.describe('TuiHint', () => { await example.apiPageExample.locator('span').hover(); await expect(page).toHaveScreenshot( - `03-hint-mode-${mode}-tuiHintShowDelay-1000__wait-0.png`, + `03-hint-mode-${mode}-tuiHintShowDelay-1000-wait-0.png`, ); await page.waitForTimeout(500); await expect(page).toHaveScreenshot( - `03-hint-mode-${mode}-tuiHintShowDelay-1000_wait-500.png`, + `03-hint-mode-${mode}-tuiHintShowDelay-1000-wait-500.png`, ); await page.waitForTimeout(500); await expect(page).toHaveScreenshot( - `03-hint-mode-${mode}-tuiHintShowDelay-1000_wait-1000.png`, + `03-hint-mode-${mode}-tuiHintShowDelay-1000-wait-1000.png`, ); }); }); @@ -126,11 +126,11 @@ test.describe('TuiHint', () => { await new TuiDocumentationPagePO(page).prepareBeforeScreenshot(); - await expect(page).toHaveScreenshot('06-hint-direction__bottom.png'); + await expect(page).toHaveScreenshot('06-hint-direction-bottom.png'); await page.setViewportSize({width: 1280, height: 150}); - await expect(page).toHaveScreenshot('06-hint-direction__left.png'); + await expect(page).toHaveScreenshot('06-hint-direction-left.png'); }); test('TuiHint customizing works', async ({page}) => { diff --git a/projects/demo-playwright/tests/deep/deep-select.pw.spec.ts b/projects/demo-playwright/tests/deep/deep-select.pw.spec.ts index 0a17b80707e9..b0e93f8334a1 100644 --- a/projects/demo-playwright/tests/deep/deep-select.pw.spec.ts +++ b/projects/demo-playwright/tests/deep/deep-select.pw.spec.ts @@ -47,7 +47,7 @@ test.describe('Deep / Select', () => { await page.waitForTimeout(100); await expect(api.apiPageExample).toHaveScreenshot( - `deep-${path}__${name}-select-option-${index}.png`, + `deep-${path}-${name}-select-option-${index}.png`, ); await select.click(); diff --git a/projects/demo-playwright/tests/deep/deep-toggle.pw.spec.ts b/projects/demo-playwright/tests/deep/deep-toggle.pw.spec.ts index 3ef4a500bc49..2194b182bf4a 100644 --- a/projects/demo-playwright/tests/deep/deep-toggle.pw.spec.ts +++ b/projects/demo-playwright/tests/deep/deep-toggle.pw.spec.ts @@ -34,7 +34,7 @@ test.describe('Deep / Toggle', () => { await page.waitForTimeout(100); await expect(api.apiPageExample).toHaveScreenshot( - `deep-${path}__${name}-toggled.png`, + `deep-${path}-${name}-toggled.png`, ); await toggle.click(); diff --git a/projects/demo-playwright/tests/kit/calendar-range/calendar-range.pw.spec.ts b/projects/demo-playwright/tests/kit/calendar-range/calendar-range.pw.spec.ts index 6265f6656dc5..44b5dc501d72 100644 --- a/projects/demo-playwright/tests/kit/calendar-range/calendar-range.pw.spec.ts +++ b/projects/demo-playwright/tests/kit/calendar-range/calendar-range.pw.spec.ts @@ -36,7 +36,7 @@ test.describe('CalendarRange', () => { example.locator('p button[data-appearance="action"]'); await expect(example).toHaveScreenshot( - '05-calendar-range-correct-display-defaults-items-and-values_1.png', + '05-calendar-range-correct-display-defaults-items-and-values-1.png', ); await calendarRange.selectItem(1); @@ -61,7 +61,7 @@ test.describe('CalendarRange', () => { await getRangeSwitcher().click(); await expect(example).toHaveScreenshot( - '05-calendar-range-correct-display-defaults-items-and-values_2.png', + '05-calendar-range-correct-display-defaults-items-and-values-2.png', ); }); diff --git a/projects/demo-playwright/tests/kit/input-table/input-table.pw.spec.ts b/projects/demo-playwright/tests/kit/input-table/input-table.pw.spec.ts index 951c2f03b2dd..2b430d40c009 100644 --- a/projects/demo-playwright/tests/kit/input-table/input-table.pw.spec.ts +++ b/projects/demo-playwright/tests/kit/input-table/input-table.pw.spec.ts @@ -21,11 +21,11 @@ test.describe('InputTable', () => { await page.waitForTimeout(300); - await expect(example).toHaveScreenshot(`01-input_table__${index}_1.png`); + await expect(example).toHaveScreenshot(`01-input-table-${index}-1.png`); await example.locator('th').nth(index).click(); - await expect(example).toHaveScreenshot(`01-input_table__${index}_2.png`); + await expect(example).toHaveScreenshot(`01-input-table-${index}-2.png`); // eslint-disable-next-line playwright/no-conditional-in-test if (index > 0) { @@ -40,7 +40,7 @@ test.describe('InputTable', () => { await page.waitForTimeout(300); // eslint-disable-next-line playwright/no-conditional-expect - await expect(example).toHaveScreenshot(`01-input_table__${index}_3.png`); + await expect(example).toHaveScreenshot(`01-input-table-${index}-3.png`); } } }); diff --git a/projects/demo-playwright/tests/kit/line-clamp/line-clamp.pw.spec.ts b/projects/demo-playwright/tests/kit/line-clamp/line-clamp.pw.spec.ts index 967919b4e17d..f53e340c7b9f 100644 --- a/projects/demo-playwright/tests/kit/line-clamp/line-clamp.pw.spec.ts +++ b/projects/demo-playwright/tests/kit/line-clamp/line-clamp.pw.spec.ts @@ -91,11 +91,11 @@ test.describe('LineClamp', () => { ); await pagePO.prepareBeforeScreenshot(); - await expect(page).toHaveScreenshot(`05-1-line-clamp__${index}.png`); + await expect(page).toHaveScreenshot(`05-1-line-clamp-${index}.png`); await pagePO.apiPageExample.locator('tui-line-clamp').hover(); - await expect(page).toHaveScreenshot(`05-2-line-clamp__${index}.png`); + await expect(page).toHaveScreenshot(`05-2-line-clamp-${index}.png`); }); }); }); diff --git a/projects/demo-playwright/tests/kit/range/range.pw.spec.ts b/projects/demo-playwright/tests/kit/range/range.pw.spec.ts index 5b7bad380dc4..607b7f47f10b 100644 --- a/projects/demo-playwright/tests/kit/range/range.pw.spec.ts +++ b/projects/demo-playwright/tests/kit/range/range.pw.spec.ts @@ -234,56 +234,48 @@ test.describe('TuiRange', () => { await range.right.focus(); await expect(output).toContainText('[ 0, 100000 ]'); - await expect(example).toHaveScreenshot('09-range-0-100_000.png'); + await expect(example).toHaveScreenshot('09-range-0-100000.png'); await page.keyboard.down('ArrowUp'); await expect(output).toContainText('[ 0, 300000 ]'); - await expect(example).toHaveScreenshot('09-range-0-300_000.png'); + await expect(example).toHaveScreenshot('09-range-0-300000.png'); await page.keyboard.down('ArrowUp'); await expect(output).toContainText('[ 0, 500000 ]'); - await expect(example).toHaveScreenshot('09-range-0-500_000.png'); + await expect(example).toHaveScreenshot('09-range-0-500000.png'); await page.keyboard.down('ArrowUp'); await expect(output).toContainText('[ 0, 750000 ]'); - await expect(example).toHaveScreenshot('09-range-0-750_000.png'); + await expect(example).toHaveScreenshot('09-range-0-750000.png'); await page.keyboard.down('ArrowUp'); await expect(output).toContainText('[ 0, 1000000 ]'); - await expect(example).toHaveScreenshot('09-range-0-1_000_000.png'); + await expect(example).toHaveScreenshot('09-range-0-1_000000.png'); await range.left.focus(); await page.keyboard.down('ArrowUp'); await expect(output).toContainText('[ 5000, 1000000 ]'); - await expect(example).toHaveScreenshot( - '09-range-5_000-1_000_000.png', - ); + await expect(example).toHaveScreenshot('09-range-5-000-1-000000.png'); await page.keyboard.down('ArrowUp'); await expect(output).toContainText('[ 10000, 1000000 ]'); - await expect(example).toHaveScreenshot( - '09-range-10_000-1_000_000.png', - ); + await expect(example).toHaveScreenshot('09-range-10000-1000000.png'); await page.keyboard.down('ArrowUp'); await expect(output).toContainText('[ 55000, 1000000 ]'); - await expect(example).toHaveScreenshot( - '09-range-55_000-1_000_000.png', - ); + await expect(example).toHaveScreenshot('09-range-55000-1000000.png'); await page.keyboard.down('ArrowUp'); await expect(output).toContainText('[ 100000, 1000000 ]'); - await expect(example).toHaveScreenshot( - '09-range-100_000-1_000_000.png', - ); + await expect(example).toHaveScreenshot('09-range-100000-1000000.png'); }); test('ArrowDown decreases value of the focused slider', async ({ @@ -293,17 +285,17 @@ test.describe('TuiRange', () => { await page.keyboard.down('ArrowDown'); await expect(output).toContainText('[ 0, 55000 ]'); - await expect(example).toHaveScreenshot('10-range-0-55_000.png'); + await expect(example).toHaveScreenshot('10-range-0-55000.png'); await page.keyboard.down('ArrowDown'); await expect(output).toContainText('[ 0, 10000 ]'); - await expect(example).toHaveScreenshot('10-range-0-10_000.png'); + await expect(example).toHaveScreenshot('10-range-0-10000.png'); await page.keyboard.down('ArrowDown'); await expect(output).toContainText('[ 0, 5000 ]'); - await expect(example).toHaveScreenshot('10-range-0-5_000.png'); + await expect(example).toHaveScreenshot('10-range-0-5000.png'); }); test('cannot set position of the LEFT slider MORE THAN position of the RIGHT slider (by ArrowUp)', async ({ diff --git a/projects/demo-playwright/tests/kit/slider/slider.pw.spec.ts b/projects/demo-playwright/tests/kit/slider/slider.pw.spec.ts index 24f1f6f69668..72d4872b5a6f 100644 --- a/projects/demo-playwright/tests/kit/slider/slider.pw.spec.ts +++ b/projects/demo-playwright/tests/kit/slider/slider.pw.spec.ts @@ -67,7 +67,7 @@ test.describe('Slider', () => { const {apiPageExample} = new TuiDocumentationPagePO(page); await expect(apiPageExample).toHaveScreenshot( - '03-min_1__max_10__value_1__segments_9.png', + '03-min-1-max-10-value-1-segments-9.png', ); }); @@ -77,7 +77,7 @@ test.describe('Slider', () => { const {apiPageExample} = new TuiDocumentationPagePO(page); await expect(apiPageExample).toHaveScreenshot( - '04-min_-5__max_5__value_1__segments_5.png', + '04-min--5-max-5-value-1-segments_5.png', ); }); diff --git a/projects/demo-playwright/tests/legacy/input-time/input-time.pw.spec.ts b/projects/demo-playwright/tests/legacy/input-time/input-time.pw.spec.ts index 19824fde16fc..723d9240ea29 100644 --- a/projects/demo-playwright/tests/legacy/input-time/input-time.pw.spec.ts +++ b/projects/demo-playwright/tests/legacy/input-time/input-time.pw.spec.ts @@ -67,7 +67,7 @@ test.describe('InputTime', () => { await inputTime.textfield.click(); - await expect(apiPageExample).toHaveScreenshot(`time_mode_${mode}.png`); + await expect(apiPageExample).toHaveScreenshot(`time-mode-${mode}.png`); }); });