Files
web2.0-frontend/tests/playwright/pages.test.ts
T
2023-10-03 20:59:42 +03:00

25 lines
657 B
TypeScript

import { test, expect } from "@playwright/test";
// import fs from "fs";
// const sitemap = fs.readFileSync("../../public/sitemap-0.xml");
// const pages = sitemap.;
// test("favicon exists", async ({ page }) => {
// await page.goto("/");
// });
// Page
// const pagePath = "/";
test("landing page renders correctly", async ({ page }) => {
await page.goto("/");
await expect(page).toHaveTitle("Aalto-yliopiston Sähköinsinöörikilta ry");
await expect(page).toHaveScreenshot("index-page.png");
});
test("404 page renders correctly", async ({ page }) => {
await page.goto("/404");
await expect(page).toHaveScreenshot("404 page.png");
});