Skip to content

Commit a8ea5ed

Browse files
committed
fixes and reporter
1 parent a78aee6 commit a8ea5ed

File tree

4 files changed

+23
-5
lines changed

4 files changed

+23
-5
lines changed

.github/workflows/playwright.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@ on:
77
jobs:
88
test:
99
timeout-minutes: 10
10+
permissions:
11+
checks: write
12+
pull-requests: read
1013
runs-on: ubuntu-latest
1114
steps:
1215
- uses: actions/checkout@v4
@@ -31,6 +34,11 @@ jobs:
3134
runs-on: ubuntu-latest
3235
steps:
3336
- uses: actions/checkout@v4
37+
- uses: actions/setup-node@v4
38+
with:
39+
node-version: lts/*
40+
- name: Install Playwright
41+
run: npm install -g @playwright/test
3442
- name: Run Playwright tests
3543
run: docker compose --profile tests run playwright
3644
- uses: actions/upload-artifact@v4
@@ -45,6 +53,11 @@ jobs:
4553
runs-on: ubuntu-latest
4654
steps:
4755
- uses: actions/checkout@v4
56+
- uses: actions/setup-node@v4
57+
with:
58+
node-version: lts/*
59+
- name: Install Playwright
60+
run: npm install -g @playwright/test
4861
- name: Run Playwright tests
4962
run: docker compose -f docker-compose.yml -f docker-compose.ent.override.yml --profile tests run playwright
5063
- uses: actions/upload-artifact@v4

docker-compose.ent.override.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
version: '3.8'
2-
31
services:
42
api:
53
environment:

docker-compose.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
version: '3.8'
2-
31
services:
42
api:
53
build:

playwright.config.ts

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,16 @@ export default defineConfig({
2222
/* Opt out of parallel tests on CI. */
2323
workers: process.env.CI ? 1 : undefined,
2424
/* Reporter to use. See https://playwright.dev/docs/test-reporters */
25-
reporter: 'html',
25+
reporter: process.env.CI ?
26+
[
27+
['html', { open: 'never' }],
28+
['github'],
29+
['junit', { outputFile: 'results.xml' }]
30+
] :
31+
[
32+
['list'],
33+
['html', { open: 'never' }]
34+
],
2635
/* Shared settings for all the projects below. See https://playwright.dev/docs/api/class-testoptions. */
2736
use: {
2837
/* Base URL to use in actions like `await page.goto('/')`. */

0 commit comments

Comments
 (0)