import { defineConfig, devices } from "@playwright/test"

export default defineConfig({
  testDir: "./docs/capture-scripts",
  outputDir: "./docs/screenshots/tenant",
  timeout: 30_000,
  retries: 0,
  workers: 1,     // séquentiel pour garder l'ordre des captures
  reporter: "list",
  use: {
    baseURL: process.env.ACX_BASE_URL || "http://localhost:3000",
    locale: "fr-FR",
    viewport: { width: 1440, height: 900 },
    deviceScaleFactor: 1.5,   // captures HD
    screenshot: "off",        // on gère manuellement
    video: "off",
    trace: "off",
  },
  projects: [
    {
      name: "chromium-docs",
      use: { ...devices["Desktop Chrome"], viewport: { width: 1440, height: 900 } },
    },
  ],
})
