18 lines
1.1 KiB
TypeScript
18 lines
1.1 KiB
TypeScript
import { defineConfig } from '../../../../../job-tracker-ui/node_modules/@playwright/test';
|
|
import base from '../../../../../job-tracker-ui/playwright.mariadb.config';
|
|
import path from 'node:path';
|
|
|
|
if (process.env.JOBTRACKER_MARIADB_BROWSER_PORT !== '33308') throw new Error('Requalification requires pinned loopback port 33308.');
|
|
if (process.env.PLAYWRIGHT_STATIC_EXPORT !== 'true' || process.env.PLAYWRIGHT_PREBUILT_EXPORT !== 'true') {
|
|
throw new Error('Requalification requires a freshly built production static export.');
|
|
}
|
|
|
|
const artifacts = path.resolve('../.artifacts/p9-requal-01/performance');
|
|
const cwd = path.resolve(__dirname, '../../../../../job-tracker-ui');
|
|
const servers = Array.isArray(base.webServer) ? base.webServer : [base.webServer!];
|
|
export default defineConfig({ ...base, testDir: '.', testMatch: 'sustained.spec.ts', workers: 1, retries: 0,
|
|
webServer: servers.map(server => ({ ...server, cwd })),
|
|
timeout: 18 * 60 * 1000, outputDir: path.join(artifacts, 'test-results'),
|
|
reporter: [['list'], ['json', { outputFile: path.join(artifacts, 'playwright-results.json') }]],
|
|
});
|