Wget-style (no-JS) clients must never receive application bytes from guarded services: copyparty serves authenticated traffic with anonymous read perms, so the guard chain is the only boundary between an unauthenticated client and the file bytes. Assertions target leakage markers in app code (Copyparty UI title, homepage panel grid, services.json JSON shape), not gate internals, so any guard-route regression fails the suite while any gate implementation passes. Also route 15-*.spec.ts into the guest project (empty storage state).
44 lines
1021 B
TypeScript
44 lines
1021 B
TypeScript
import { defineConfig } from "@playwright/test";
|
|
import { BASE_URL, REAL_UA } from "./lib/env";
|
|
|
|
export default defineConfig({
|
|
testDir: "./specs",
|
|
timeout: 90_000,
|
|
expect: { timeout: 20_000 },
|
|
retries: 1,
|
|
workers: 2,
|
|
fullyParallel: false,
|
|
reporter: [["list"]],
|
|
outputDir: "./test-results",
|
|
use: {
|
|
baseURL: BASE_URL,
|
|
userAgent: REAL_UA,
|
|
ignoreHTTPSErrors: true,
|
|
viewport: { width: 1440, height: 900 },
|
|
trace: "retain-on-failure",
|
|
},
|
|
projects: [
|
|
{
|
|
name: "setup",
|
|
testMatch: /00-auth\.setup\.ts/,
|
|
},
|
|
{
|
|
name: "standard",
|
|
testMatch: /(10|12|13)-.*\.spec\.ts/,
|
|
use: { storageState: ".auth/qa-e2e.json" },
|
|
dependencies: ["setup"],
|
|
},
|
|
{
|
|
name: "admin",
|
|
testMatch: /11-.*\.spec\.ts/,
|
|
use: { storageState: ".auth/qa-e2e-admin.json" },
|
|
dependencies: ["setup"],
|
|
},
|
|
{
|
|
name: "guest",
|
|
testMatch: /(14|15)-.*\.spec\.ts/,
|
|
use: { storageState: { cookies: [], origins: [] } },
|
|
},
|
|
],
|
|
});
|