-
Notifications
You must be signed in to change notification settings - Fork 534
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[CI] Break "Linux Tests" into 2 parallel jobs. (#9642)
The "Linux Tests" stage/job regularly approaches an hour runtime, after a ~17 minute Linux build. This puts it beyond our "ideal" 1 hour PR CI build. Manually split the job up into 2 jobs that each run in parallel to reduce the overall runtime.
- Loading branch information
Showing
3 changed files
with
115 additions
and
87 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
87 changes: 87 additions & 0 deletions
87
build-tools/automation/yaml-templates/stage-linux-tests.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
# Runs smoke tests on Linux packages. | ||
|
||
stages: | ||
- stage: linux_tests | ||
displayName: Linux Tests | ||
dependsOn: | ||
- mac_build | ||
- linux_build | ||
jobs: | ||
# Check - "Xamarin.Android (Linux Tests Linux > Tests > MSBuild)" | ||
- job: linux_tests_smoke_1 | ||
displayName: Linux > Tests > MSBuild 1 | ||
pool: | ||
name: MAUI-1ESPT | ||
image: $(LinuxPoolImage1ESPT) | ||
os: linux | ||
timeoutInMinutes: 180 | ||
workspace: | ||
clean: all | ||
steps: | ||
- template: /build-tools/automation/yaml-templates/setup-test-environment.yaml | ||
|
||
- task: DownloadPipelineArtifact@2 | ||
inputs: | ||
artifactName: $(TestAssembliesArtifactName) | ||
downloadPath: $(System.DefaultWorkingDirectory)/bin/Test$(XA.Build.Configuration) | ||
|
||
- template: /build-tools/automation/yaml-templates/run-nunit-tests.yaml | ||
parameters: | ||
testRunTitle: Xamarin.Android.Build.Tests - Linux BuildTest | ||
testAssembly: $(System.DefaultWorkingDirectory)/bin/Test$(XA.Build.Configuration)/$(DotNetStableTargetFramework)/Xamarin.Android.Build.Tests.dll | ||
dotNetTestExtraArgs: --filter "Name = BuildTest" | ||
|
||
- template: /build-tools/automation/yaml-templates/upload-results.yaml | ||
parameters: | ||
configuration: $(XA.Build.Configuration) | ||
artifactName: Test Results - MSBuild - Linux 1 | ||
|
||
- template: /build-tools/automation/yaml-templates/fail-on-issue.yaml | ||
|
||
- job: linux_tests_smoke_2 | ||
displayName: Linux > Tests > MSBuild 2 | ||
pool: | ||
name: MAUI-1ESPT | ||
image: $(LinuxPoolImage1ESPT) | ||
os: linux | ||
timeoutInMinutes: 180 | ||
workspace: | ||
clean: all | ||
steps: | ||
- template: /build-tools/automation/yaml-templates/setup-test-environment.yaml | ||
|
||
- task: DownloadPipelineArtifact@2 | ||
inputs: | ||
artifactName: $(TestAssembliesArtifactName) | ||
downloadPath: $(System.DefaultWorkingDirectory)/bin/Test$(XA.Build.Configuration) | ||
|
||
- template: /build-tools/automation/yaml-templates/run-nunit-tests.yaml | ||
parameters: | ||
testRunTitle: Xamarin.Android.Build.Tests - Linux PackagingTest | ||
testAssembly: $(System.DefaultWorkingDirectory)/bin/Test$(XA.Build.Configuration)/$(DotNetStableTargetFramework)/Xamarin.Android.Build.Tests.dll | ||
dotNetTestExtraArgs: --filter "Name = PackagingTest" | ||
|
||
- template: /build-tools/automation/yaml-templates/run-nunit-tests.yaml | ||
parameters: | ||
testRunTitle: Xamarin.Android.Build.Tests - Linux XASdkTests | ||
testAssembly: $(System.DefaultWorkingDirectory)/bin/Test$(XA.Build.Configuration)/$(DotNetStableTargetFramework)/Xamarin.Android.Build.Tests.dll | ||
dotNetTestExtraArgs: --filter "Name = XASdkTests & Name != XamarinLegacySdk" | ||
|
||
- template: /build-tools/automation/yaml-templates/run-nunit-tests.yaml | ||
parameters: | ||
testRunTitle: Xamarin.Android.Build.Tests - Linux AndroidDependenciesTests | ||
testAssembly: $(System.DefaultWorkingDirectory)/bin/Test$(XA.Build.Configuration)/$(DotNetStableTargetFramework)/Xamarin.Android.Build.Tests.dll | ||
dotNetTestExtraArgs: --filter "Name = AndroidDependenciesTests" | ||
|
||
- task: ShellScript@2 | ||
displayName: Test dotnet-local.sh | ||
inputs: | ||
scriptPath: dotnet-local.sh | ||
args: build samples/HelloWorld/HelloWorld/HelloWorld.DotNet.csproj | ||
|
||
- template: /build-tools/automation/yaml-templates/upload-results.yaml | ||
parameters: | ||
configuration: $(XA.Build.Configuration) | ||
artifactName: Test Results - MSBuild - Linux 2 | ||
|
||
- template: /build-tools/automation/yaml-templates/fail-on-issue.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters