test: add MVP QA gate

This commit is contained in:
vince 2026-06-18 19:41:29 +02:00
parent af09f705b1
commit 081d6085a5
10 changed files with 413 additions and 7 deletions

38
playwright.config.ts Normal file
View file

@ -0,0 +1,38 @@
import { defineConfig, devices } from "@playwright/test";
const port = Number(process.env.PLAYWRIGHT_PORT || 4173);
const baseURL = `http://127.0.0.1:${port}`;
export default defineConfig({
testDir: "tests/e2e",
fullyParallel: true,
forbidOnly: !!process.env.CI,
retries: process.env.CI ? 2 : 0,
reporter: process.env.CI ? [["github"], ["list"]] : "list",
use: {
baseURL,
trace: "retain-on-failure",
screenshot: "only-on-failure",
},
webServer: {
command: `DATABASE_URL=file:./data/playwright.sqlite bun run dev -- --port ${port}`,
url: baseURL,
reuseExistingServer: !process.env.CI,
timeout: 120_000,
},
projects: [
{
name: "chromium-desktop",
use: {
...devices["Desktop Chrome"],
viewport: { width: 1440, height: 1000 },
},
},
{
name: "chromium-mobile",
use: {
...devices["Pixel 7"],
},
},
],
});