mirror of
https://github.com/aljazceru/claude-code-viewer.git
synced 2025-12-27 10:14:28 +01:00
47 lines
912 B
TypeScript
47 lines
912 B
TypeScript
import { defineConfig, devices } from '@playwright/test';
|
|
|
|
const isCI = process.env['CI'] === 'true';
|
|
|
|
/**
|
|
* See https://playwright.dev/docs/test-configuration.
|
|
*/
|
|
export default defineConfig({
|
|
testDir: './e2e',
|
|
fullyParallel: true,
|
|
forbidOnly: isCI,
|
|
retries: isCI ? 2 : 0,
|
|
workers: isCI ? 1 : undefined,
|
|
reporter: 'html',
|
|
use: {
|
|
baseURL: 'http://localhost:4000',
|
|
trace: 'on-first-retry',
|
|
screenshot: 'only-on-failure',
|
|
},
|
|
|
|
|
|
projects: [
|
|
{
|
|
name: 'chromium',
|
|
use: { ...devices['Desktop Chrome'] },
|
|
},
|
|
|
|
{
|
|
name: 'Mobile Chrome',
|
|
use: { ...devices['Pixel 5'] },
|
|
},
|
|
|
|
{
|
|
name: 'Mobile Safari',
|
|
use: { ...devices['iPhone 12'] },
|
|
},
|
|
],
|
|
|
|
webServer: {
|
|
command: 'pnpm start:e2e',
|
|
url: 'http://localhost:4000',
|
|
reuseExistingServer: false,
|
|
env: {
|
|
GLOBAL_CLAUDE_DIR: './mock-global-claude-dir'
|
|
}
|
|
},
|
|
}); |