26
26
27
27
jobs :
28
28
job_install_deps :
29
- name : Install Dependencies
29
+ name : Install Dependencies - Linux
30
30
runs-on : ubuntu-latest
31
31
timeout-minutes : 15
32
32
steps :
@@ -43,17 +43,43 @@ jobs:
43
43
uses : actions/cache@v2
44
44
id : cache_dependencies
45
45
with :
46
- path : ${{ env.CACHED_DEPENDENCY_PATHS }}
46
+ path : ${{ env.CACHED_DEPENDENCY_PATHS }}-linux
47
47
key : ${{ steps.compute_lockfile_hash.outputs.hash }}
48
48
- name : Install dependencies
49
49
if : steps.cache_dependencies.outputs.cache-hit == ''
50
50
run : yarn install --ignore-engines
51
51
outputs :
52
52
dependency_cache_key : ${{ steps.compute_lockfile_hash.outputs.hash }}
53
53
54
+ job_install_deps_windows :
55
+ name : Install Dependencies - Windows
56
+ runs-on : windows-latest
57
+ timeout-minutes : 15
58
+ steps :
59
+ - name : Check out current commit (${{ github.sha }})
60
+ uses : actions/checkout@v2
61
+ - name : Set up Node
62
+ uses : actions/setup-node@v1
63
+ # we use a hash of yarn.lock as our cache key, because if it hasn't changed, our dependencies haven't changed,
64
+ # so no need to reinstall them
65
+ - name : Compute dependency cache key
66
+ id : compute_lockfile_hash
67
+ run : echo "::set-output name=hash::${{ hashFiles('yarn.lock') }}"
68
+ - name : Check dependency cache
69
+ uses : actions/cache@v2
70
+ id : cache_dependencies
71
+ with :
72
+ path : ${{ env.CACHED_DEPENDENCY_PATHS }}-windows
73
+ key : ${{ steps.compute_lockfile_hash.outputs.hash }}
74
+ - name : Install dependencies
75
+ if : steps.cache_dependencies.outputs.cache-hit == ''
76
+ run : yarn install --ignore-engines
77
+ outputs :
78
+ dependency_cache_key_windows : ${{ steps.compute_lockfile_hash.outputs.hash }}
79
+
54
80
job_build :
55
81
name : Build
56
- needs : job_install_deps
82
+ needs : [ job_install_deps, job_install_deps_windows]
57
83
runs-on : ubuntu-latest
58
84
timeout-minutes : 15
59
85
steps :
64
90
- name : Check dependency cache
65
91
uses : actions/cache@v2
66
92
with :
67
- path : ${{ env.CACHED_DEPENDENCY_PATHS }}
93
+ path : ${{ env.CACHED_DEPENDENCY_PATHS }}-linux
68
94
key : ${{ needs.job_install_deps.outputs.dependency_cache_key }}
69
95
- name : Check build cache
70
96
uses : actions/cache@v2
91
117
# this needs to be passed on, because the `needs` context only looks at direct ancestors (so steps which depend on
92
118
# `job_build` can't see `job_install_deps` and what it returned)
93
119
dependency_cache_key : ${{ needs.job_install_deps.outputs.dependency_cache_key }}
120
+ dependency_cache_key_windows : ${{ needs.job_install_deps_windows.outputs.dependency_cache_key_windows }}
94
121
95
122
job_size_check :
96
123
name : Size Check
@@ -107,7 +134,7 @@ jobs:
107
134
- name : Check dependency cache
108
135
uses : actions/cache@v2
109
136
with :
110
- path : ${{ env.CACHED_DEPENDENCY_PATHS }}
137
+ path : ${{ env.CACHED_DEPENDENCY_PATHS }}-linux
111
138
key : ${{ needs.job_build.outputs.dependency_cache_key }}
112
139
- name : Check build cache
113
140
uses : actions/cache@v2
@@ -137,7 +164,7 @@ jobs:
137
164
- name : Check dependency cache
138
165
uses : actions/cache@v2
139
166
with :
140
- path : ${{ env.CACHED_DEPENDENCY_PATHS }}
167
+ path : ${{ env.CACHED_DEPENDENCY_PATHS }}-linux
141
168
key : ${{ needs.job_build.outputs.dependency_cache_key }}
142
169
- name : Check build cache
143
170
uses : actions/cache@v2
@@ -160,7 +187,7 @@ jobs:
160
187
- name : Check dependency cache
161
188
uses : actions/cache@v2
162
189
with :
163
- path : ${{ env.CACHED_DEPENDENCY_PATHS }}
190
+ path : ${{ env.CACHED_DEPENDENCY_PATHS }}-linux
164
191
key : ${{ needs.job_build.outputs.dependency_cache_key }}
165
192
- name : Check build cache
166
193
uses : actions/cache@v2
@@ -171,7 +198,7 @@ jobs:
171
198
run : yarn circularDepCheck
172
199
173
200
job_unit_test :
174
- name : Test (Node ${{ matrix.node }})
201
+ name : Test (Node ${{ matrix.node }} - Linux )
175
202
needs : job_build
176
203
continue-on-error : true
177
204
timeout-minutes : 30
@@ -189,20 +216,47 @@ jobs:
189
216
- name : Check dependency cache
190
217
uses : actions/cache@v2
191
218
with :
192
- path : ${{ env.CACHED_DEPENDENCY_PATHS }}
219
+ path : ${{ env.CACHED_DEPENDENCY_PATHS }}-linux
193
220
key : ${{ needs.job_build.outputs.dependency_cache_key }}
194
221
- name : Check build cache
195
222
uses : actions/cache@v2
196
223
with :
197
224
path : ${{ env.CACHED_BUILD_PATHS }}
198
225
key : ${{ env.BUILD_CACHE_KEY }}
199
226
- name : Run tests
200
- env :
201
- NODE_VERSION : ${{ matrix.node }}
202
- run : ./scripts/test.sh
227
+ run : node ./scripts/test.js
203
228
- name : Compute test coverage
204
229
uses : codecov/codecov-action@v1
205
230
231
+ job_unit_test_windows :
232
+ name : Test (Node ${{ matrix.node }} - Windows)
233
+ needs : job_build
234
+ continue-on-error : true
235
+ timeout-minutes : 30
236
+ runs-on : windows-latest
237
+ strategy :
238
+ matrix :
239
+ node : [6, 8, 10, 12, 14, 16]
240
+ steps :
241
+ - name : Check out current commit (${{ github.sha }})
242
+ uses : actions/checkout@v2
243
+ - name : Set up Node
244
+ uses : actions/setup-node@v1
245
+ with :
246
+ node-version : ${{ matrix.node }}
247
+ - name : Check dependency cache
248
+ uses : actions/cache@v2
249
+ with :
250
+ path : ${{ env.CACHED_DEPENDENCY_PATHS }}-windows
251
+ key : ${{ needs.job_build.outputs.dependency_cache_key_windows }}
252
+ - name : Check build cache
253
+ uses : actions/cache@v2
254
+ with :
255
+ path : ${{ env.CACHED_BUILD_PATHS }}
256
+ key : ${{ env.BUILD_CACHE_KEY }}
257
+ - name : Run tests
258
+ run : node ./scripts/test.js
259
+
206
260
# Ember tests are separate from the rest because they are the slowest part of the test suite, and making them a
207
261
# separate job allows them to run in parallel with the other tests.
208
262
job_ember_tests :
@@ -231,7 +285,7 @@ jobs:
231
285
- name : Check dependency cache
232
286
uses : actions/cache@v2
233
287
with :
234
- path : ${{ env.CACHED_DEPENDENCY_PATHS }}
288
+ path : ${{ env.CACHED_DEPENDENCY_PATHS }}-linux
235
289
key : ${{ needs.job_build.outputs.dependency_cache_key }}
236
290
- name : Check build cache
237
291
uses : actions/cache@v2
@@ -255,7 +309,7 @@ jobs:
255
309
- name : Check dependency cache
256
310
uses : actions/cache@v2
257
311
with :
258
- path : ${{ env.CACHED_DEPENDENCY_PATHS }}
312
+ path : ${{ env.CACHED_DEPENDENCY_PATHS }}-linux
259
313
key : ${{ needs.job_build.outputs.dependency_cache_key }}
260
314
- name : Check build cache
261
315
uses : actions/cache@v2
@@ -289,7 +343,7 @@ jobs:
289
343
- name : Check dependency cache
290
344
uses : actions/cache@v2
291
345
with :
292
- path : ${{ env.CACHED_DEPENDENCY_PATHS }}
346
+ path : ${{ env.CACHED_DEPENDENCY_PATHS }}-linux
293
347
key : ${{ needs.job_build.outputs.dependency_cache_key }}
294
348
- name : Check build cache
295
349
uses : actions/cache@v2
@@ -322,7 +376,7 @@ jobs:
322
376
- name : Check dependency cache
323
377
uses : actions/cache@v2
324
378
with :
325
- path : ${{ env.CACHED_DEPENDENCY_PATHS }}
379
+ path : ${{ env.CACHED_DEPENDENCY_PATHS }}-linux
326
380
key : ${{ needs.job_build.outputs.dependency_cache_key }}
327
381
- name : Check build cache
328
382
uses : actions/cache@v2
@@ -351,7 +405,7 @@ jobs:
351
405
- name : Check dependency cache
352
406
uses : actions/cache@v2
353
407
with :
354
- path : ${{ env.CACHED_DEPENDENCY_PATHS }}
408
+ path : ${{ env.CACHED_DEPENDENCY_PATHS }}-linux
355
409
key : ${{ needs.job_build.outputs.dependency_cache_key }}
356
410
- name : Check build cache
357
411
uses : actions/cache@v2
0 commit comments