mirror of
https://github.com/zhigang1992/react-navigation.git
synced 2026-01-12 22:51:18 +08:00
Hey! I made the following changes: - Replaced Jest by the new Playwright test-runner - Disabled the Jest linting rules for the Playwright e2e tests - Rewrote the tests to the new test-runner - Adjusted `Link.test.ts` which should be less flaky - The tests run now across all three browsers: Chromium, Firefox, and WebKit See here for reference about the new test-runner: https://playwright.dev/docs/test-intro I extracted a fix for Netlify in #9668. Let me know if you have any questions.
29 lines
602 B
TypeScript
29 lines
602 B
TypeScript
import type { PlaywrightTestConfig } from '@playwright/test';
|
|
import path from 'path';
|
|
|
|
const config: PlaywrightTestConfig = {
|
|
testDir: path.join(__dirname, 'tests'),
|
|
globalSetup: require.resolve('./config/setup-server.ts'),
|
|
globalTeardown: require.resolve('./config/teardown-server.ts'),
|
|
workers: 1,
|
|
reporter: 'list',
|
|
projects: [
|
|
{
|
|
name: 'Chromium',
|
|
use: { browserName: 'chromium' },
|
|
},
|
|
|
|
{
|
|
name: 'Firefox',
|
|
use: { browserName: 'firefox' },
|
|
},
|
|
|
|
{
|
|
name: 'WebKit',
|
|
use: { browserName: 'webkit' },
|
|
},
|
|
],
|
|
};
|
|
|
|
export default config;
|