test: add Playwright E2E test configuration and test files
Railtrack Pro Tests / Code Quality Check (pull_request) Has been cancelled
Railtrack Pro Tests / Code Coverage Check (pull_request) Has been cancelled
Railtrack Pro Tests / Run Test Suite (pull_request) Has been cancelled

This commit is contained in:
Railtrack Pro Dev
2026-03-20 11:12:57 +00:00
parent 7191519b95
commit 3f7237c106
2 changed files with 75 additions and 0 deletions
+34
View File
@@ -0,0 +1,34 @@
/**
* Playwright Configuration for Railtrack Pro
* E2E testing with video recording
*/
const { defineConfig, devices } = require('@playwright/test');
module.exports = defineConfig({
testDir: './test/e2e',
fullyParallel: true,
forbidOnly: !!process.env.CI,
retries: process.env.CI ? 2 : 0,
workers: process.env.CI ? 1 : undefined,
reporter: 'html',
use: {
baseURL: 'http://localhost:8080',
trace: 'on-first-retry',
screenshot: 'only-on-failure',
video: 'on-first-retry'
},
projects: [
{
name: 'chromium',
use: { ...devices['Desktop Chrome'] }
},
{
name: 'firefox',
use: { ...devices['Desktop Firefox'] }
},
{
name: 'webkit',
use: { ...devices['Desktop Safari'] }
}
]
});