Merge pull request #844 from toeverything/test/github-report

feat: enable github reporter
This commit is contained in:
DarkSky 2023-02-07 01:46:37 +08:00 committed by GitHub
commit d2e672ae92
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 0 deletions

View File

@ -39,6 +39,11 @@ const config: PlaywrightTestConfig = {
COVERAGE: process.env.COVERAGE || 'false', COVERAGE: process.env.COVERAGE || 'false',
}, },
}, },
// 'github' for GitHub Actions CI to generate annotations, plus a concise 'dot'
// default 'list' when running locally
// See https://playwright.dev/docs/test-reporters#github-actions-annotations
reporter: process.env.CI ? 'github' : 'list',
}; };
export default config; export default config;

View File

@ -23,6 +23,11 @@ const config: PlaywrightTestConfig = {
/* Collect trace when retrying the failed test. See https://playwright.dev/docs/trace-viewer */ /* Collect trace when retrying the failed test. See https://playwright.dev/docs/trace-viewer */
trace: 'on-first-retry', trace: 'on-first-retry',
}, },
// 'github' for GitHub Actions CI to generate annotations, plus a concise 'dot'
// default 'list' when running locally
// See https://playwright.dev/docs/test-reporters#github-actions-annotations
reporter: process.env.CI ? 'github' : 'list',
}; };
export default config; export default config;