import { defineConfig, devices } from '@playwright/test';

/**
 * Playwright config for smoke testing the live/deployed site.
 * No local dev server needed — tests hit the real URL.
 *
 * Usage: SMOKE_BASE_URL=https://llmhosts.com npx playwright test --config=playwright.smoke.config.ts
 */
export default defineConfig({
  testDir: './e2e',
  testMatch: 'smoke-*.spec.ts',
  fullyParallel: false,
  retries: 0,
  workers: 1,
  reporter: [['list']],
  timeout: 60000,

  use: {
    baseURL: process.env.SMOKE_BASE_URL || 'https://llmhosts.com',
    trace: 'retain-on-failure',
    screenshot: 'on',
    video: 'retain-on-failure',
  },

  projects: [
    {
      name: 'chromium',
      use: { ...devices['Desktop Chrome'] },
    },
  ],
});
