feat: add Playwright configuration for dev-audit
This commit is contained in:
@@ -0,0 +1,45 @@
|
||||
import { defineConfig, devices } from '@playwright/test';
|
||||
import { getEnvironmentConfig } from './shared/config/environments';
|
||||
|
||||
const config = defineConfig({
|
||||
testDir: './dev-audit',
|
||||
fullyParallel: true,
|
||||
forbidOnly: !!process.env.CI,
|
||||
retries: process.env.CI ? 2 : 0,
|
||||
workers: process.env.CI ? 1 : undefined,
|
||||
reporter: [
|
||||
['html', { outputFolder: 'test-framework/reports/html' }],
|
||||
['json', { outputFile: 'test-framework/reports/results.json' }],
|
||||
['list']
|
||||
],
|
||||
use: {
|
||||
baseURL: getEnvironmentConfig(process.env.TEST_ENV || 'development').baseURL,
|
||||
trace: 'on-first-retry',
|
||||
screenshot: 'only-on-failure',
|
||||
video: 'retain-on-failure'
|
||||
},
|
||||
projects: [
|
||||
{
|
||||
name: 'chromium',
|
||||
use: { ...devices['Desktop Chrome'] },
|
||||
},
|
||||
{
|
||||
name: 'firefox',
|
||||
use: { ...devices['Desktop Firefox'] },
|
||||
},
|
||||
{
|
||||
name: 'webkit',
|
||||
use: { ...devices['Desktop Safari'] },
|
||||
},
|
||||
{
|
||||
name: 'Mobile Chrome',
|
||||
use: { ...devices['Pixel 5'] },
|
||||
},
|
||||
{
|
||||
name: 'Mobile Safari',
|
||||
use: { ...devices['iPhone 12'] },
|
||||
}
|
||||
]
|
||||
});
|
||||
|
||||
export default config;
|
||||
Reference in New Issue
Block a user