/
azure-pipelines.yml
96 lines (76 loc) Β· 2 KB
/
azure-pipelines.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
jobs:
- job: Chore
pool:
vmImage: 'Ubuntu 16.04'
variables:
TERM: screen-256color
os_name: Linux
steps:
- task: NodeTool@0
inputs:
versionSpec: 10.x
displayName: 'Install Node.js'
- bash: |
npm install -g yarn@1.17.2
displayName: "Install Yarn 1.17.2+"
- bash: |
YARN_ENABLE_NETWORK=0 node ./scripts/run-yarn.js --frozen-lockfile
displayName: "Check that the Yarn files don't change on new installs"
- bash: |
if [[ $(git diff --name-only "$(git merge-base origin/"$SYSTEM_PULLREQUEST_TARGETBRANCH" HEAD)" HEAD -- .yarn/{cache,virtual} | wc -l) -gt 0 ]]; then
rm -rf ./.yarn/cache
node ./scripts/run-yarn.js
fi
displayName: 'Check that the cache files are consistent with their remote sources'
condition: eq(variables['Build.Reason'], 'PullRequest')
- bash: |
[[ $(node ./scripts/run-yarn.js cache clean --dry-run --json | jq -c 'select(.path)' | wc -l) -eq 0 ]]
displayName: "Check that the cache doesn't contain obsolete packages"
- bash: |
node ./scripts/run-yarn.js test:lint
displayName: 'Check the linting passes'
- job: Windows
pool:
vmImage: 'vs2017-win2016'
variables:
TERM: screen-256color
os_name: Windows
strategy:
matrix:
# "Node 8.x":
# node_version: 8.x
"Node 10.x":
node_version: 10.x
steps:
- bash: |
git config core.symlinks true
git reset --hard
- template: scripts/azure-run-tests.yml
- job: Linux
pool:
vmImage: 'Ubuntu 16.04'
variables:
TERM: screen-256color
os_name: Linux
strategy:
matrix:
"Node 8.x":
node_version: 8.x
"Node 10.x":
node_version: 10.x
steps:
- template: scripts/azure-run-tests.yml
- job: OSX
pool:
vmImage: 'macOS 10.13'
variables:
TERM: screen-256color
os_name: OSX
strategy:
matrix:
"Node 8.x":
node_version: 8.x
"Node 10.x":
node_version: 10.x
steps:
- template: scripts/azure-run-tests.yml