8a36950235
- playwright.config.ts with authenticated test projects - e2e/auth.setup.ts authenticates via OIDC or token - e2e/rook.spec.ts smoke tests for sidebar, overview page, storage classes navigation, and plugin settings - scripts/deploy-e2e-headlamp.sh deploys Headlamp + rook in headlamp-dev - scripts/teardown-e2e-headlamp.sh cleans up after tests - e2e.yaml uses reusable workflow from .github repo - @playwright/test ^1.58.2 devDep added - PRI-640 Co-Authored-By: Paperclip <noreply@paperclip.ing>
28 lines
761 B
TypeScript
28 lines
761 B
TypeScript
import { defineConfig, devices } from '@playwright/test';
|
|
|
|
export default defineConfig({
|
|
testDir: './e2e',
|
|
timeout: 30_000,
|
|
expect: { timeout: 10_000 },
|
|
fullyParallel: false,
|
|
forbidOnly: !!process.env.CI,
|
|
retries: process.env.CI ? 1 : 0,
|
|
reporter: 'list',
|
|
use: {
|
|
baseURL: process.env.HEADLAMP_URL || (() => { throw new Error('HEADLAMP_URL is required — run scripts/deploy-e2e-headlamp.sh first'); })(),
|
|
trace: 'on-first-retry',
|
|
screenshot: 'only-on-failure',
|
|
},
|
|
projects: [
|
|
{ name: 'setup', testMatch: /auth\.setup\.ts/, timeout: 60_000 },
|
|
{
|
|
name: 'chromium',
|
|
use: {
|
|
...devices['Desktop Chrome'],
|
|
storageState: 'e2e/.auth/state.json',
|
|
},
|
|
dependencies: ['setup'],
|
|
},
|
|
],
|
|
});
|