File tree Expand file tree Collapse file tree 1 file changed +14
-30
lines changed Expand file tree Collapse file tree 1 file changed +14
-30
lines changed Original file line number Diff line number Diff line change 7
7
- master
8
8
- main
9
9
- develop
10
+ - stage
11
+ - support/*
10
12
pull_request :
11
13
branches :
12
- - master
13
14
- main
15
+ - develop
16
+
14
17
jobs :
15
- test_linux :
18
+ tests :
16
19
name : ${{ matrix.os }}
17
20
strategy :
18
21
fail-fast : false
19
22
matrix :
20
- os : [ubuntu-20.04]
23
+ os : [ubuntu-20.04, windows-2019 ]
21
24
runs-on : ${{ matrix.os }}
22
25
steps :
23
26
- uses : actions/checkout@v2
24
27
- uses : actions/setup-node@v1
25
28
with :
26
- node-version : 16
27
- - uses : microsoft/playwright-github-action@v1
28
- - uses : actions/cache@v1
29
- with :
30
- path : ~/.npm
31
- key : ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
32
- restore-keys : |
33
- ${{ runner.os }}-node-
34
- - name : Install dependencies
35
- run : npm ci
36
- - name : Run tests
37
- run : npm test
38
- test_win :
39
- name : " Windows"
40
- runs-on : windows-latest
41
- steps :
42
- - uses : actions/checkout@v2
43
- - uses : actions/setup-node@v1
44
- with :
45
- node-version : 16
29
+ node-version : 18
46
30
- uses : microsoft/playwright-github-action@v1
47
31
- uses : actions/cache@v1
48
32
with :
@@ -54,29 +38,29 @@ jobs:
54
38
run : npm ci
55
39
- name : Run tests
56
40
run : npm test
41
+
57
42
tag :
58
43
name : " Publishing release"
59
- if : github.ref == 'refs/heads/main' || github.ref == 'refs/heads/master '
44
+ if : github.event_name != 'pull_request' && github.ref == 'refs/heads/main '
60
45
needs :
61
- - test_linux
62
- - test_win
63
- runs-on : ubuntu-latest
46
+ - tests
47
+ runs-on : self-hosted
64
48
steps :
65
49
- name : Checkout code
66
50
uses : actions/checkout@v2
67
51
with :
68
52
fetch-depth : 0
69
53
- uses : actions/setup-node@v2
70
54
with :
71
- node-version : ' 16 .x'
55
+ node-version : ' 18 .x'
72
56
registry-url : ' https://registry.npmjs.org'
73
- - uses : actions/cache@v2
57
+ - uses : actions/cache@v1
74
58
with :
75
59
path : ~/.npm
76
60
key : ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
77
61
restore-keys : |
78
62
${{ runner.os }}-node-
79
- - run : npm install
63
+ - run : npm ci
80
64
- name : Read version from package.json
81
65
uses : culshaw/read-package-node-version-actions@v1
82
66
id : package-node-version
You can’t perform that action at this time.
0 commit comments