47 lines
1.8 KiB
TypeScript
47 lines
1.8 KiB
TypeScript
import { test, expect } from "./fixtures/console-gate";
|
|
|
|
test.describe("TIRREDESIGN-30 — standalone header and footer", () => {
|
|
test("Russian standalone pages render Aeroflot shell around React content", async ({
|
|
page,
|
|
consoleMessages,
|
|
}) => {
|
|
await page.goto("/ru/smoke");
|
|
await page.waitForLoadState("domcontentloaded");
|
|
|
|
const header = page.getByTestId("standalone-header");
|
|
await expect(header).toBeVisible();
|
|
await expect(header).toContainText("Купить билет");
|
|
await expect(header).toContainText("Аэроэкспресс");
|
|
await expect(header).toContainText("Тестовая версия");
|
|
|
|
await expect(page.locator("#main-content h1")).toHaveText("Страница проверки");
|
|
|
|
const footer = page.getByTestId("standalone-footer");
|
|
await expect(footer).toBeVisible();
|
|
await expect(footer).toContainText("Контакты");
|
|
await expect(footer).toContainText("8 (800) 444-55-55");
|
|
await expect(footer).toContainText("© Авиакомпания «Аэрофлот» 2008-2026");
|
|
});
|
|
|
|
test("English standalone pages localize shell chrome", async ({
|
|
page,
|
|
consoleMessages,
|
|
}) => {
|
|
await page.goto("/en/smoke");
|
|
await page.waitForLoadState("domcontentloaded");
|
|
|
|
const header = page.getByTestId("standalone-header");
|
|
await expect(header).toBeVisible();
|
|
await expect(header).toContainText("Book a flight");
|
|
await expect(header).toContainText("Aeroexpress");
|
|
await expect(header).toContainText("Test version");
|
|
|
|
await expect(page.locator("#main-content h1")).toHaveText("Smoke test page");
|
|
|
|
const footer = page.getByTestId("standalone-footer");
|
|
await expect(footer).toBeVisible();
|
|
await expect(footer).toContainText("Contacts");
|
|
await expect(footer).toContainText("© Aeroflot 2008-2026");
|
|
});
|
|
});
|