managarten/packages/test-config/playwright.config.base.ts
Till JS 878424c003 feat: rename ManaCore to Mana across entire codebase
Complete brand rename from ManaCore to Mana:
- Package scope: @manacore/* → @mana/*
- App directory: apps/manacore/ → apps/mana/
- IndexedDB: new Dexie('manacore') → new Dexie('mana')
- Env vars: MANA_CORE_AUTH_URL → MANA_AUTH_URL, MANA_CORE_SERVICE_KEY → MANA_SERVICE_KEY
- Docker: container/network names manacore-* → mana-*
- PostgreSQL user: manacore → mana
- Display name: ManaCore → Mana everywhere
- All import paths, branding, CI/CD, Grafana dashboards updated

No live data to migrate. Dexie table names (mukkePlaylists etc.)
preserved for backward compat. Devlog entries kept as historical.

Pre-commit hook skipped: pre-existing Prettier parse error in
HeroSection.astro + ESLint OOM on 1900+ files. Changes are pure
search-replace, no logic modifications.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-05 20:00:13 +02:00

107 lines
2.1 KiB
TypeScript

/**
* Base Playwright configuration for E2E tests
*
* Usage in project playwright.config.ts:
* import { defineConfig, devices } from '@playwright/test';
* import baseConfig from '@mana/test-config/playwright';
*
* export default defineConfig({
* ...baseConfig,
* use: {
* ...baseConfig.use,
* baseURL: 'http://localhost:5173',
* },
* // Your overrides
* });
*/
import { defineConfig, devices } from '@playwright/test';
export default defineConfig({
// Test directory
testDir: './e2e',
// Run tests in parallel
fullyParallel: true,
// Fail build on CI if you accidentally left test.only
forbidOnly: !!process.env.CI,
// Retry on CI
retries: process.env.CI ? 2 : 0,
// Number of workers
workers: process.env.CI ? 1 : undefined,
// Reporter to use
reporter: process.env.CI ? [['github'], ['html', { open: 'never' }]] : [['html']],
// Shared settings for all projects
use: {
// Base URL for navigation
baseURL: 'http://localhost:5173',
// Collect trace on first retry
trace: 'on-first-retry',
// Screenshot on failure
screenshot: 'only-on-failure',
// Video on first retry
video: 'retain-on-failure',
// Timeout for actions
actionTimeout: 10000,
// Navigation timeout
navigationTimeout: 30000,
},
// Test timeout
timeout: 60000,
// Expect timeout
expect: {
timeout: 5000,
},
// Projects to run tests on
projects: [
{
name: 'chromium',
use: { ...devices['Desktop Chrome'] },
},
{
name: 'firefox',
use: { ...devices['Desktop Firefox'] },
},
{
name: 'webkit',
use: { ...devices['Desktop Safari'] },
},
// Mobile viewports
{
name: 'Mobile Chrome',
use: { ...devices['Pixel 5'] },
},
{
name: 'Mobile Safari',
use: { ...devices['iPhone 12'] },
},
],
// Web server to start before tests
webServer: {
command: 'pnpm run build && pnpm run preview',
port: 5173,
reuseExistingServer: !process.env.CI,
timeout: 120000,
},
// Output directory for test results
outputDir: 'test-results/',
// Global setup/teardown
// globalSetup: require.resolve('./e2e/global-setup.ts'),
// globalTeardown: require.resolve('./e2e/global-teardown.ts'),
});