-
Notifications
You must be signed in to change notification settings - Fork 7
99 lines (97 loc) · 2.65 KB
/
playwright-tests.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
name: run playwright tests
on:
push:
branches: [ dev-playwright ]
pull_request:
branches: [ dev-playwright ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- id: checkout
uses: actions/checkout@v4
- id: cache-node
name: Cache node modules
uses: actions/cache@v3
with:
path: |
'**/node'
'**/node_modules'
~/.m2/repository
key: ${{ runner.os }}-node_modules-${{ hashFiles('**/package.json') }}
- id: setup-java
name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'adopt'
- id: setup-maven
name: Setup Maven
uses: stCarolas/setup-maven@v5
with:
maven-version: 3.9.0
- id: create_settings_xml
name: Create settings.xml
uses: whelk-io/maven-settings-xml-action@v22
with:
repositories: >
[
{
"id": "central",
"url": "http://central",
"releases": {
"enabled": "true"
},
"snapshots": {
"enabled": "true"
}
}
]
plugin_repositories: >
[
{
"id": "central",
"url": "http://central",
"releases": {
"enabled": "true"
},
"snapshots": {
"enabled": "true"
}
}
]
servers: >
[
{
"id": "${{ secrets.NEXUS_ID }}",
"username": "${{ secrets.NEXUS_USER }}",
"password": "${{ secrets.NEXUS_USER_PW }}"
}
]
mirrors: >
[
{
"id": "${{ secrets.NEXUS_ID }}",
"mirrorOf": "central",
"url": "${{ secrets.NEXUS_URL }}"
}
]
- id: tests
name: Run tests
run: mvn prepare-package -B -ntp -Prun-js-tests,include-mapapps-deps
shell: bash
- uses: actions/setup-node@v4
with:
node-version: lts/*
- name: Install dependencies
run: npm ci
- name: Install Playwright Browsers
run: npx playwright install --with-deps chromium
- name: Run Playwright tests
run: npx playwright test
- uses: actions/upload-artifact@v4
if: ${{ !cancelled() }}
with:
name: playwright-report
path: ./target/e2e-tests-reports
retention-days: 10