personal-website-sveltekit/playwright.config.ts

33 lines
723 B
TypeScript
Raw Permalink Normal View History

import type { PlaywrightTestConfig } from '@playwright/test';
const config: PlaywrightTestConfig = {
webServer: {
2025-08-25 04:45:06 +00:00
command: 'pnpm -s exec svelte-kit sync && pnpm run build && pnpm run preview',
port: 4173,
timeout: 180_000,
reuseExistingServer: true
},
testDir: 'tests',
testMatch: /(.+\.)?(test|spec)\.[jt]s/,
use: {
baseURL: 'http://localhost:4173'
},
// Run on main browsers: Chromium (Chrome), Firefox, WebKit (Safari)
projects: [
{
name: 'chromium',
use: { browserName: 'chromium' }
},
{
name: 'firefox',
use: { browserName: 'firefox' }
},
{
name: 'webkit',
use: { browserName: 'webkit' }
}
]
};
export default config;