mirror of
https://github.com/nexu-io/open-design.git
synced 2026-10-27 09:51:12 +01:00
* Optimize e2e tools-dev runtime parallelism * Remove visual networkidle wait * Optimize e2e vitest parallelism * Optimize Nix flake caching * Test CI on Blacksmith runners * Allow parallel manual CI runs * Tier CI runner sizes * Temporarily narrow CI debug scope * Instrument watcher CI timeouts * Instrument watcher event diagnostics * Avoid default polling in watcher tests * Skip runtime trace during watcher debug * Probe ARM runner tiers for CI * Focus CI runner probe on x64 browser * Probe browser workers by runner size * Probe Playwright file parallelism * Probe Playwright worker scaling on 8v * Reshape CI topology * Fix split E2E Vitest CI lane * Simplify daemon CI topology * Optimize Windows payload CI setup * Revert "Optimize Windows payload CI setup" This reverts commit5cbc48c0af. * Cache better-sqlite3 Nix binding separately * Revert "Cache better-sqlite3 Nix binding separately" This reverts commit0384e3787e. * Remove unused Nix cache setup from CI * Use Blacksmith ARM for lightweight CI jobs
47 lines
1.4 KiB
TypeScript
47 lines
1.4 KiB
TypeScript
import { defineConfig, devices } from '@playwright/test';
|
|
|
|
function parseWorkerCount(value: string | undefined): number {
|
|
if (value == null || value.length === 0) return 2;
|
|
const parsed = Number(value);
|
|
if (!Number.isInteger(parsed) || parsed < 1) {
|
|
throw new Error(`OD_PLAYWRIGHT_WORKERS must be a positive integer, got: ${value}`);
|
|
}
|
|
return parsed;
|
|
}
|
|
|
|
export default defineConfig({
|
|
testDir: './ui',
|
|
outputDir: './ui/reports/test-results',
|
|
timeout: Number(process.env.OD_PLAYWRIGHT_TIMEOUT) || 30_000,
|
|
retries: process.env.CI ? 1 : 0,
|
|
expect: {
|
|
timeout: 10_000,
|
|
},
|
|
fullyParallel: process.env.OD_PLAYWRIGHT_FULLY_PARALLEL === '1',
|
|
workers: parseWorkerCount(process.env.OD_PLAYWRIGHT_WORKERS),
|
|
reporter: process.env.CI
|
|
? [
|
|
['github'],
|
|
['list'],
|
|
['html', { open: 'never', outputFolder: './ui/reports/playwright-html-report' }],
|
|
['json', { outputFile: './ui/reports/results.json' }],
|
|
['junit', { outputFile: './ui/reports/junit.xml' }],
|
|
]
|
|
: [
|
|
['list'],
|
|
['html', { open: 'never', outputFolder: './ui/reports/playwright-html-report' }],
|
|
['json', { outputFile: './ui/reports/results.json' }],
|
|
['junit', { outputFile: './ui/reports/junit.xml' }],
|
|
],
|
|
use: {
|
|
trace: 'on-first-retry',
|
|
screenshot: 'only-on-failure',
|
|
},
|
|
projects: [
|
|
{
|
|
name: 'chromium',
|
|
use: { ...devices['Desktop Chrome'] },
|
|
},
|
|
],
|
|
});
|