forked from jestjs/jest
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.azure-pipelines-steps.yml
46 lines (37 loc) · 1.1 KB
/
.azure-pipelines-steps.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
#
# Steps for building and testing Jest. See jobs defined in .azure-pipelines.yml
#
steps:
- checkout: self
path: jest
# Ensure Node.js 14 is active
- task: NodeTool@0
inputs:
versionSpec: '14.x'
displayName: 'Use Node.js 14'
# Ensure Python 2.7 is active
- task: UsePythonVersion@0
inputs:
versionSpec: '2.7'
displayName: 'Use Python 2.7'
- bash: echo "##vso[task.setvariable variable=folder;isOutput=true]$(yarn config get cacheFolder)"
name: yarnCache
- task: Cache@2
inputs:
key: yarn | $(Agent.OS) | yarn.lock
path: $(yarnCache.folder)
displayName: Cache Yarn packages
- script: yarn install --immutable
displayName: 'Install dependencies'
- script: yarn build:js
displayName: 'Transpile TypeScript'
# Run test-ci-partial
- script: yarn run test-ci-partial
displayName: 'Run tests'
# Publish CI test results
- task: PublishTestResults@2
inputs:
testResultsFiles: '**/reports/junit/*.xml'
testRunTitle: 'CI Tests $(Agent.OS)'
displayName: 'Publish test results'
condition: succeededOrFailed()