Spaces:
Running

WorkPilot-AI / web /playwright.staging.config.ts
Aynkhn's picture
Deploy WorkPilot demo (part 3)
03608f2 verified
Raw History Blame Contribute Delete
954 Bytes
import { defineConfig, devices } from "@playwright/test";
// Phase 18: end-to-end checks against a DEPLOYED environment (cd.yml, after the staging
// deploy). Unlike playwright.config.ts it starts no servers and needs no test-only API routes:
// it signs in with the public demo tenant (seeded by `python -m core.cli seed-demo`).
// E2E_BASE_URL=https://staging.example.com E2E_EMAIL=... E2E_PASSWORD=... \
// npx playwright test -c playwright.staging.config.ts
const BASE = process.env.E2E_BASE_URL ?? "http://127.0.0.1:3000";
export default defineConfig({
testDir: "./e2e-staging",
timeout: 90_000,
expect: { timeout: 20_000 },
workers: 1,
retries: process.env.CI ? 2 : 0,
reporter: process.env.CI ? [["list"], ["html", { open: "never" }]] : "list",
use: { baseURL: BASE, trace: "retain-on-failure", ...devices["Desktop Chrome"] },
projects: [{ name: "chromium", use: { ...devices["Desktop Chrome"] } }],
});