Use preinstalled chrome for tests in CI

This commit is contained in:
Alejandro Celaya
2026-08-06 10:18:56 +02:00
parent cc112c9a31
commit 0d884aca6b
2 changed files with 4 additions and 2 deletions

View File

@@ -13,4 +13,3 @@ jobs:
with: with:
node-version: 26.x node-version: 26.x
publish-coverage: true publish-coverage: true
install-playwright: true

View File

@@ -41,7 +41,10 @@ export default defineConfig({
test: { test: {
// Run tests in an actual browser // Run tests in an actual browser
browser: { browser: {
provider: playwright(), provider: playwright({
// In CI, this instructs playwright to use a pre-existing Chrome instance
launchOptions: process.env.CI ? { channel: 'chrome' } : undefined,
}),
enabled: true, enabled: true,
headless: true, headless: true,
screenshotFailures: false, screenshotFailures: false,