47 lines
1.1 KiB
TypeScript
47 lines
1.1 KiB
TypeScript
import { defineConfig, devices } from "@playwright/test"
|
||
|
||
/**
|
||
* Playwright config for video tours (demos, not tests).
|
||
*
|
||
* Usage:
|
||
* yarn tour # run all tours (desktop)
|
||
* yarn tour:mobile # run all tours (mobile)
|
||
*
|
||
* Videos are saved to video-tours/output/
|
||
*/
|
||
export default defineConfig({
|
||
testDir: "./tours",
|
||
testMatch: "**/*.tour.ts",
|
||
outputDir: "./output",
|
||
fullyParallel: false,
|
||
retries: 0,
|
||
workers: 1,
|
||
reporter: "list",
|
||
/* No global setup/teardown – tours are self-contained */
|
||
|
||
use: {
|
||
baseURL: process.env.CODING_URL || "https://localhost:3000",
|
||
headless: true,
|
||
ignoreHTTPSErrors: true,
|
||
video: { mode: "on", size: { width: 1280, height: 720 } },
|
||
navigationTimeout: 30000,
|
||
launchOptions: {
|
||
args: ["--no-sandbox"],
|
||
},
|
||
},
|
||
|
||
projects: [
|
||
{
|
||
name: "tour-desktop",
|
||
use: { ...devices["Desktop Chrome"] },
|
||
},
|
||
{
|
||
name: "tour-mobile",
|
||
use: {
|
||
...devices["iPhone 12"],
|
||
defaultBrowserType: "chromium",
|
||
},
|
||
},
|
||
],
|
||
})
|