Skip to content

Commit 1ba3a91

Browse files
Split up test jobs so that they can be run concurrently (#1056)
* Split up test jobs so that they can be run concurrently * Use checkout actions v4
1 parent bff8434 commit 1ba3a91

File tree

1 file changed

+38
-7
lines changed

1 file changed

+38
-7
lines changed

.github/workflows/pull-request.yml

Lines changed: 38 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,17 @@ name: Pull request
33
on: pull_request
44

55
jobs:
6-
build:
7-
name: Pull request
6+
sonar_analysis:
7+
name: Sonar analysis
88
runs-on: ubuntu-latest
9-
109
steps:
11-
- uses: actions/checkout@v4
12-
10+
- uses: actions/checkout@v2
1311
- uses: actions/setup-node@v4
1412
with:
1513
node-version: 20
1614
cache: 'npm'
17-
1815
- name: Install dependencies
1916
run: npm ci
20-
2117
- name: Sonar analysis
2218
uses: sonarsource/sonarcloud-github-action@master
2319
with:
@@ -27,11 +23,46 @@ jobs:
2723
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
2824
SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }}
2925

26+
linting:
27+
name: Code style checks
28+
runs-on: ubuntu-latest
29+
steps:
30+
- uses: actions/checkout@v4
31+
- uses: actions/setup-node@v4
32+
with:
33+
node-version: 20
34+
cache: 'npm'
35+
- name: Install dependencies
36+
run: npm ci
3037
- name: Run linting
3138
run: npm run lint
3239

40+
tests:
41+
name: Javascript unit tests
42+
runs-on: ubuntu-latest
43+
steps:
44+
- uses: actions/checkout@v4
45+
- uses: actions/setup-node@v4
46+
with:
47+
node-version: 20
48+
cache: 'npm'
49+
- name: Install dependencies
50+
run: npm ci
3351
- name: Run tests
3452
run: npm test
3553

54+
ui_tests:
55+
name: Visual regression tests
56+
runs-on: ubuntu-latest
57+
steps:
58+
- uses: actions/checkout@v4
59+
- uses: actions/setup-node@v4
60+
with:
61+
node-version: 20
62+
cache: 'npm'
63+
- name: Install dependencies
64+
run: npm ci
65+
- name: Run tests
66+
run: npm test
3667
- name: Run backstop
3768
run: npm run backstop:ci

0 commit comments

Comments
 (0)