forked from microsoft/accessibility-insights-web
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.yaml
124 lines (104 loc) · 4.57 KB
/
build.yaml
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
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.
trigger: # trigger only affects CI builds
branches:
include:
- master
pr: # pr does not trigger CI builds
branches:
include:
- '*' # must quote since "*" is a YAML reserved character; we want a string
jobs:
- job: 'unit_tests_and_lints'
pool:
vmImage: 'macOS-10.14'
steps:
- template: pipeline/install-node-prerequisites.yaml
- script: yarn lint:check
displayName: check lint errors
timeoutInMinutes: 5
- script: yarn format:check
displayName: check formatting errors
timeoutInMinutes: 5
- script: yarn copyright:check
displayName: check copyrightheaders
timeoutInMinutes: 1
- script: yarn scss:build
displayName: generate typings for scss files
timeoutInMinutes: 3
- script: yarn test --ci
displayName: run unit tests
timeoutInMinutes: 10
- task: PublishTestResults@2
inputs:
testResultsFiles: $(System.DefaultWorkingDirectory)/test-results/unit/junit.xml
testRunTitle: $(Agent.JobName)
condition: always()
displayName: publish test results
timeoutInMinutes: 3
- task: PublishCodeCoverageResults@1
inputs:
codeCoverageTool: Cobertura
summaryFileLocation: $(System.DefaultWorkingDirectory)/test-results/unit/coverage/cobertura-coverage.xml
failIfCoverageEmpty: true
# We care most about the summary information; adding the detailed files doesn't give enough extra information
# to be worth the 1min it adds to the build.
# Consider re-enabling this once https://github.com/Microsoft/azure-pipelines-tasks/issues/4945 is resolved.
# reportDirectory: $(System.DefaultWorkingDirectory)/test-results/unit/coverage/lcov-report
displayName: publish code coverage
timeoutInMinutes: 5
- script: yarn publish-code-coverage -t $(CODECOV_TOKEN)
displayName: Publish code coverage to codecov
timeoutInMinutes: 3
- job: 'publish_build_drops'
pool:
vmImage: 'ubuntu-16.04'
steps:
- template: pipeline/install-node-prerequisites.yaml
- task: ComponentGovernanceComponentDetection@0
displayName: 'dependency detection (Component Governance)'
condition: and(succeeded(), in(variables['Build.Reason'], 'IndividualCI', 'BatchedCI'))
inputs:
detectorsFilter: Yarn
ignoreDirectories: 'drop,dist,extension,node_modules'
verbosity: Normal
timeoutInMinutes: 5
- task: msospo.ospo-extension.8d7f9abb-6896-461d-9e25-4f74ed65ddb2.notice@0
displayName: 'generate NOTICE.html file'
condition: and(succeeded(), in(variables['Build.Reason'], 'IndividualCI', 'BatchedCI'))
inputs:
outputfile: '$(System.DefaultWorkingDirectory)/src/NOTICE.html'
outputformat: html
timeoutInMinutes: 5
- script: yarn build:all
displayName: build:all
timeoutInMinutes: 10
- task: PublishBuildArtifacts@1
inputs:
pathtoPublish: '$(System.DefaultWorkingDirectory)/drop'
artifactName: 'drop'
displayName: publish drop
timeoutInMinutes: 5
- job: 'e2e_mac_web_unified'
pool:
vmImage: macOS-10.14
steps:
- template: pipeline/install-node-prerequisites.yaml
- template: pipeline/e2e-test-from-agent.yaml
- template: pipeline/e2e-test-publish-results.yaml
- template: pipeline/unified/unified-e2e-test-interactive.yaml
- template: pipeline/unified/unified-e2e-publish-results.yaml
- job: 'e2e_linux_unified'
pool:
vmImage: ubuntu-16.04
steps:
- template: pipeline/install-node-prerequisites.yaml
- template: pipeline/unified/unified-e2e-test-linux.yaml
- template: pipeline/unified/unified-e2e-publish-results.yaml
- job: 'e2e_windows_unified'
pool:
vmImage: windows-latest
steps:
- template: pipeline/install-node-prerequisites.yaml
- template: pipeline/unified/unified-e2e-test-interactive.yaml
- template: pipeline/unified/unified-e2e-publish-results.yaml