mirror of
https://github.com/AmruthPillai/Reactive-Resume.git
synced 2026-10-04 02:33:47 +10:00
Remove the Semantic CSS acceptance suite (six specs, fifteen visual baselines, and its fixtures) along with the --grep-invert that excluded it from CI. With the serial PDF preflight gone, Playwright can run four workers in CI instead of one. Also drop the slowest and most redundant specs: PDF raster direction, thumbnail resolution, import reproduction, imported tables, picture rendering, and literal whitespace, plus the basic authored-page guidance, settings profile, and resume lifecycle checks already covered elsewhere. Trim the OAuth consent matrix to allow and deny on an existing session.
45 lines
1.0 KiB
TypeScript
45 lines
1.0 KiB
TypeScript
import { defineConfig, devices } from "@playwright/test";
|
|
|
|
const port = Number.parseInt(process.env.PORT ?? "3000", 10);
|
|
const baseURL = process.env.APP_URL ?? `http://localhost:${port}`;
|
|
const isCI = process.env.CI === "true" || process.env.CI === "1";
|
|
|
|
export default defineConfig({
|
|
testDir: "./tests/e2e/specs",
|
|
fullyParallel: true,
|
|
forbidOnly: isCI,
|
|
retries: 0,
|
|
workers: isCI ? 4 : undefined,
|
|
timeout: 30_000,
|
|
expect: {
|
|
timeout: 10_000,
|
|
},
|
|
reporter: isCI
|
|
? [["list"], ["github"], ["junit", { outputFile: "test-results/e2e-junit.xml" }]]
|
|
: [["list"], ["html", { open: "never" }]],
|
|
use: {
|
|
baseURL,
|
|
trace: "retain-on-failure",
|
|
screenshot: "only-on-failure",
|
|
video: "retain-on-failure",
|
|
},
|
|
projects: [
|
|
{
|
|
name: "chromium",
|
|
use: { ...devices["Desktop Chrome"] },
|
|
},
|
|
],
|
|
webServer: {
|
|
command: "pnpm start",
|
|
url: `${baseURL}/api/health`,
|
|
reuseExistingServer: !isCI,
|
|
timeout: 120_000,
|
|
env: {
|
|
...process.env,
|
|
APP_URL: baseURL,
|
|
NODE_ENV: "production",
|
|
PORT: String(port),
|
|
},
|
|
},
|
|
});
|