test(e2e): isolate puppeteer from vitest to prevent CI pipeline crash
Some checks failed
Build & Deploy / 🔍 Prepare (push) Successful in 9s
Build & Deploy / 🧪 QA (push) Successful in 2m41s
Build & Deploy / 🏗️ Build (push) Failing after 21s
Build & Deploy / 🚀 Deploy (push) Has been skipped
Build & Deploy / 🧪 Post-Deploy Verification (push) Has been skipped
Build & Deploy / 🔔 Notify (push) Successful in 2s
CI - Lint, Typecheck & Test / quality-assurance (pull_request) Failing after 3m40s

This commit is contained in:
2026-03-03 14:19:36 +01:00
parent d5dd66b832
commit 70f189b0c9
3 changed files with 3 additions and 1 deletions

View File

@@ -101,6 +101,7 @@
"typecheck": "tsc --noEmit",
"test": "vitest run --passWithNoTests",
"test:og": "vitest run tests/og-image.test.ts",
"test:e2e": "vitest run tests/*.e2e.test.ts",
"check:og": "tsx scripts/check-og-images.ts",
"check:a11y": "pa11y-ci",
"check:wcag": "tsx ./scripts/wcag-sitemap.ts",

View File

@@ -14,6 +14,7 @@ const BASE_URL = process.env.TEST_URL || 'http://127.0.0.1:3000';
beforeAll(async () => {
browser = await puppeteer.launch({
headless: true,
executablePath: process.env.PUPPETEER_EXECUTABLE_PATH || process.env.CHROME_PATH || undefined,
args: ['--no-sandbox', '--disable-setuid-sandbox'],
});
});

View File

@@ -15,7 +15,7 @@ export default defineConfig({
test: {
environment: 'happy-dom',
globals: true,
exclude: ['**/node_modules/**', '**/.next/**', '**/dist/**'],
exclude: ['**/node_modules/**', '**/.next/**', '**/dist/**', '**/*.e2e.test.ts'],
include: ['**/*.test.{ts,tsx}'],
coverage: {
provider: 'v8',