import { defineConfig } from "@playwright/test"; const WEB_PORT = process.env.WEB_SMOKE_PORT ?? "3100"; const MOCK_PORT = process.env.MOCK_PORT ?? "8765"; export default defineConfig({ testDir: "./tests", fullyParallel: false, timeout: 30_000, retries: 0, use: { baseURL: `http://127.0.0.1:${WEB_PORT}`, }, webServer: [ { command: `node tests/mock-server.mjs`, url: `http://127.0.0.1:${MOCK_PORT}/api/v1/health`, reuseExistingServer: true, timeout: 10_000, env: { MOCK_PORT }, }, { command: `next dev -p ${WEB_PORT}`, url: `http://127.0.0.1:${WEB_PORT}`, reuseExistingServer: true, timeout: 60_000, env: { MONLET_API_BASE_URL: `http://127.0.0.1:${MOCK_PORT}`, MONLET_API_TOKEN: "smoke", }, }, ], });