/**
 * Playwright config for QA trading-floor tests against existing dev servers.
 * Used by TEC-3040 — runs against apps/api :3001 and apps/web :3000 (already running).
 * No webServer startup — assumes both servers are up with dev DB.
 */
import { defineConfig, devices } from '@playwright/test';

export default defineConfig({
  testDir: './e2e',
  fullyParallel: false,
  forbidOnly: false,
  retries: 1,
  workers: 1,
  reporter: [
    ['html', { open: 'never', outputFolder: 'playwright-report-qa' }],
    ['list'],
  ],
  use: {
    trace: 'on-first-retry',
    screenshot: 'only-on-failure',
    video: 'retain-on-failure',
  },
  projects: [
    {
      name: 'web',
      testDir: './e2e/web',
      use: {
        ...devices['Desktop Chrome'],
        baseURL: 'http://localhost:3000',
      },
    },
  ],
  // No webServer — relies on existing running servers
});
