forked from dotnet/maui
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathstage-helix-tests.yml
More file actions
105 lines (101 loc) · 3.53 KB
/
Copy pathstage-helix-tests.yml
File metadata and controls
105 lines (101 loc) · 3.53 KB
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
# Template for running tests on Helix on dnceng
parameters:
- name: prepareSteps
type: stepList
default: []
- name: postSteps
type: stepList
default: []
- name: enableSourceBuild
type: boolean
default: false
- name: enableSourceIndex
type: boolean
default: false
- name: sourceIndexParams
type: object
default: []
- name: publishAssets
type: boolean
default: false
- name: enableMicrobuild
type: boolean
default: false
- name: runAsPublic
type: boolean
default: true
- name: helixInternal
type: string
default: ''
- name: HelixAccessToken
type: string
default: ''
- name: creator
type: string
default: 'maui'
- name: extraHelixArguments
type: string
default: ''
- name: buildTaskProjects
type: string
default: '$(Build.SourcesDirectory)/Microsoft.Maui.BuildTasks.slnf'
- name: helixProject
type: string
default: '$(Build.SourcesDirectory)/eng/helix.proj'
- name: buildConfigurations
type: object
default:
- Debug
- Release
- name: helixPool
type: object
stages:
- stage: HelixTests
displayName: Run Helix Unit Tests
dependsOn: []
jobs:
- ${{ each BuildConfiguration in parameters.buildConfigurations }}:
- template: ${{ iif(eq(parameters.runAsPublic, 'true'), '/eng/common/templates/jobs/jobs.yml@self', '/eng/common/templates-official/jobs/jobs.yml@self') }}
parameters:
helixRepo: dotnet/maui
pool: ${{ parameters.helixPool }}
enableMicrobuild: ${{ parameters.enableMicrobuild }}
enablePublishUsingPipelines: true
enablePublishBuildAssets: ${{ parameters.publishAssets }}
enableTelemetry: true
enableSourceBuild: ${{ parameters.enableSourceBuild }}
enableSourceIndex: ${{ parameters.enableSourceIndex }}
sourceIndexParams: ${{ parameters.sourceIndexParams }}
publishAssetsImmediately: true
enablePublishBuildArtifacts: true
enablePublishTestResults: false
workspace:
clean: all
jobs:
- job: test_helix_unit_tests_windows_${{ BuildConfiguration }}
displayName: Windows Helix Unit Tests (${{ BuildConfiguration }})
timeoutInMinutes: 240
variables:
- name: _BuildConfig
value: ${{ BuildConfiguration }}
steps:
- ${{ each step in parameters.prepareSteps }}:
- ${{ each pair in step }}:
${{ pair.key }}: ${{ pair.value }}
- script: dotnet cake --target=dotnet-buildtasks --configuration="${{ BuildConfiguration }}" --verbosity=diagnostic
displayName: 🛠️ Provision SDK & Build BuildTasks
retryCountOnTaskFailure: 3
env:
DOTNET_TOKEN: $(dotnetbuilds-internal-container-read-token)
PRIVATE_BUILD: $(PrivateBuild)
- script: $(_msbuildCommand) "${{ parameters.helixProject }}" -warnAsError 0 -restore /p:Configuration=${{ BuildConfiguration }} /p:EnableHelixJobMonitor=true /p:HelixInternal="${{ parameters.helixInternal }}" /p:TestRunNameSuffix="_${{ BuildConfiguration }}" /p:SkipInitInternalTooling=true /bl:$(Build.Arcade.LogsPath)${{ BuildConfiguration }}/helix_tests.binlog ${{ parameters.extraHelixArguments }}
displayName: Run Helix Tests
env:
SYSTEM_ACCESSTOKEN: $(System.AccessToken)
HelixAccessToken: ${{ parameters.HelixAccessToken }}
- template: /eng/common/core-templates/job/helix-job-monitor.yml
parameters:
timeoutInMinutes: 360
organization: dotnet
repository: maui
helixAccessToken: ${{ parameters.HelixAccessToken }}