mirror of
https://github.com/snapotter-hq/SnapOtter.git
synced 2026-08-03 07:46:42 +02:00
- Fix SKIP_MUST_CHANGE_PASSWORD not affecting login/session API responses, causing frontend redirect even when the env var was set after user creation - Increase Docker Playwright timeouts (test: 600s, expect: 60s, AI processing: 300s) to support CPU-only self-hosted environments - Increase default rate limit from 100 to 50000 req/min for self-hosted deployments - Fix OCR tests: use filechooser pattern (Dropzone has no static file input), correct enhance checkbox default, rewrite for actual fixture behavior - Fix remove-bg tests: update quality labels (Balanced→HD, Best→Max) - Fix noise-removal skip guard: use waitFor() instead of instant isVisible() - Fix automate pipeline save test: clean up stale E2E pipelines before assertion
44 lines
1.1 KiB
TypeScript
44 lines
1.1 KiB
TypeScript
import path from "node:path";
|
|
import { defineConfig, devices } from "@playwright/test";
|
|
|
|
const authFile = path.join(__dirname, "test-results", ".auth", "user.json");
|
|
|
|
// Point raw-fetch tests (api.spec, security.spec, people.spec, rbac.spec) at
|
|
// the Docker container instead of the dev-server default (port 13490).
|
|
// Start the container with: SKIP_MUST_CHANGE_PASSWORD=true docker compose -f docker/docker-compose.yml up -d
|
|
process.env.API_URL ??= "http://localhost:1349";
|
|
|
|
export default defineConfig({
|
|
testDir: "./tests/e2e",
|
|
timeout: 600_000,
|
|
expect: {
|
|
timeout: 60_000,
|
|
},
|
|
fullyParallel: false,
|
|
retries: 0,
|
|
workers: 1,
|
|
reporter: [["html", { open: "never" }], ["list"]],
|
|
use: {
|
|
baseURL: "http://localhost:1349",
|
|
screenshot: "only-on-failure",
|
|
trace: "retain-on-failure",
|
|
},
|
|
projects: [
|
|
{
|
|
name: "setup",
|
|
testMatch: /auth\.setup\.ts/,
|
|
},
|
|
{
|
|
name: "chromium",
|
|
use: {
|
|
...devices["Desktop Chrome"],
|
|
storageState: authFile,
|
|
},
|
|
dependencies: ["setup"],
|
|
},
|
|
],
|
|
// No webServer — tests run against the Docker container at localhost:1349
|
|
});
|
|
|
|
export { authFile };
|