Enhance Jenkinsfile for frontend testing and update Playwright configuration
- Added a new 'E2E (docker compose + Playwright)' stage in the Jenkinsfile to run end-to-end tests using Docker Compose and Playwright. - Updated the 'Test frontend' stage to utilize the Playwright test image and improved error handling for missing files. - Modified Playwright configuration to use an environment variable for the base URL, enhancing flexibility in CI environments. - Expanded TypeScript configuration to include additional test and configuration files for better type checking.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { defineConfig } from '@playwright/test';
|
||||
import { fileURLToPath } from 'url';
|
||||
import path from 'path';
|
||||
import { fileURLToPath } from 'node:url';
|
||||
import path from 'node:path';
|
||||
|
||||
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
||||
|
||||
@@ -13,7 +13,7 @@ export default defineConfig({
|
||||
forbidOnly: inCI,
|
||||
timeout: 60000,
|
||||
use: {
|
||||
baseURL: 'http://localhost:5173',
|
||||
baseURL: process.env.PLAYWRIGHT_TEST_BASE_URL || 'http://localhost:5173',
|
||||
// Sin display en agentes de integración: obligatorio headless
|
||||
headless: inCI ? true : false
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user