Files
LinkPort/web/playwright.config.ts

28 lines
821 B
TypeScript

import { defineConfig } from "@playwright/test";
const origin = `http://127.0.0.1:${process.env.LINKPORT_E2E_PORT || '18081'}`;
const authOrigin = `http://127.0.0.1:${process.env.LINKPORT_E2E_AUTH_PORT || '18082'}`;
export default defineConfig({
testDir: "./tests",
testMatch: "**/*.spec.ts",
workers: 1,
timeout: 45000,
use: {
baseURL: origin,
channel: process.env.LINKPORT_BROWSER_CHANNEL || "msedge",
viewport: { width: 1440, height: 1000 },
trace: "off",
screenshot: "only-on-failure",
},
webServer: [{
command: "node tests/start-server.mjs",
url: `${origin}/healthz`,
timeout: 30000,
reuseExistingServer: false,
}, {
command: "node tests/start-server.mjs --auth",
url: `${authOrigin}/healthz`,
timeout: 30000,
reuseExistingServer: false,
}],
});