In an effort to better utilize CI resources, this change will only run the System.Runtime library test per PR for Android and Wasm configurations. The full libraries and runtime tests will move to only run on the post-PR validation pipeline.
The summary of changes are:
- System.Runtime tests will only trigger per PR for Android x86/x64 and Wasm AOT / EAT
- All mono runtime builds will only run on the post PR validation build (rolling build)
- WasmBuildTests will only run on the post PR validation build (rolling build)
- Wasm on Windows will only build
Note: iOS/tvOS/MacCatalyst are excluded until #59503 lands
- name: _BuildConfig
value: $(buildConfigUpper)
+
+ - name: _runSmokeTestsOnlyArg
+ ${{ if ne(parameters.variables['isFullMatrix'], true) }}:
+ value: /p:RunSmokeTestsOnly=true
+ ${{ if eq(parameters.variables['isFullMatrix'], true) }}:
+ value: ''
- ${{ if or(eq(parameters.osGroup, 'windows'), eq(parameters.hostedOs, 'windows')) }}:
- name: archiveExtension
jobParameters:
testGroup: innerloop
nameSuffix: AllSubsets_Mono
- buildArgs: -s mono+libs+host+packs+libs.tests -c $(_BuildConfig) /p:ArchiveTests=true
+ buildArgs: -s mono+libs+host+packs+libs.tests -c $(_BuildConfig) /p:ArchiveTests=true $(_runSmokeTestsOnlyArg)
timeoutInMinutes: 180
condition: >-
or(
jobParameters:
testGroup: innerloop
nameSuffix: AllSubsets_Mono
- buildArgs: -s mono+libs+host+packs+libs.tests -c $(_BuildConfig) /p:ArchiveTests=true
+ buildArgs: -s mono+libs+host+packs+libs.tests -c $(_BuildConfig) /p:ArchiveTests=true $(_runSmokeTestsOnlyArg)
timeoutInMinutes: 180
condition: >-
or(
eq(dependencies.evaluate_paths.outputs['SetPathVars_mono.containsChange'], true),
eq(dependencies.evaluate_paths.outputs['SetPathVars_installer.containsChange'], true),
eq(variables['isFullMatrix'], true))
-
- # don't run tests on PRs until we can get significantly more devices
+ # Device tests are rolling build only
${{ if eq(variables['isFullMatrix'], true) }}:
# extra steps, run tests
extraStepsTemplate: /eng/pipelines/libraries/helix.yml
buildConfig: Release
runtimeFlavor: mono
platforms:
- - Android_x64
+ - Android_x64
variables:
- ${{ if and(eq(variables['System.TeamProject'], 'public'), eq(variables['Build.Reason'], 'PullRequest')) }}:
- name: _HelixSource
eq(dependencies.evaluate_paths.outputs['SetPathVars_runtimetests.containsChange'], true),
eq(dependencies.evaluate_paths.outputs['SetPathVars_mono.containsChange'], true),
eq(variables['isFullMatrix'], true))
- # extra steps, run tests
- extraStepsTemplate: /eng/pipelines/common/templates/runtimes/android-runtime-and-send-to-helix.yml
- extraStepsParameters:
- creator: dotnet-bot
- testRunNamePrefixSuffix: Mono_$(_BuildConfig)
+ # NOTE: Per PR test execution is not recommended for runtime tests
+ ${{ if eq(variables['isFullMatrix'], true) }}:
+ # extra steps, run tests
+ extraStepsTemplate: /eng/pipelines/common/templates/runtimes/android-runtime-and-send-to-helix.yml
+ extraStepsParameters:
+ creator: dotnet-bot
+ testRunNamePrefixSuffix: Mono_$(_BuildConfig)
#
# Build the whole product using Mono and run runtime tests with the JIT.
buildConfig: Release
runtimeFlavor: mono
platforms:
- - iOSSimulator_x64
+ - iOSSimulator_x64
variables:
- ${{ if and(eq(variables['System.TeamProject'], 'public'), eq(variables['Build.Reason'], 'PullRequest')) }}:
- name: _HelixSource
buildConfig: Release
runtimeFlavor: mono
platforms:
- - Android_arm64
+ - Android_arm64
variables:
- ${{ if and(eq(variables['System.TeamProject'], 'public'), eq(variables['Build.Reason'], 'PullRequest')) }}:
- name: _HelixSource
eq(dependencies.evaluate_paths.outputs['SetPathVars_mono.containsChange'], true),
eq(dependencies.evaluate_paths.outputs['SetPathVars_installer.containsChange'], true),
eq(variables['isFullMatrix'], true))
- # extra steps, run tests
- extraStepsTemplate: /eng/pipelines/libraries/helix.yml
- extraStepsParameters:
- creator: dotnet-bot
- testRunNamePrefixSuffix: Mono_$(_BuildConfig)
- extraHelixArguments: /p:BrowserHost=windows
- scenarios:
- - normal
- - wasmtestonbrowser
- condition: >-
- or(
- eq(variables['librariesContainsChange'], true),
- eq(variables['monoContainsChange'], true),
- eq(variables['isFullMatrix'], true))
+ ${{ if eq(variables['isFullMatrix'], true) }}:
+ # extra steps, run tests
+ extraStepsTemplate: /eng/pipelines/libraries/helix.yml
+ extraStepsParameters:
+ creator: dotnet-bot
+ testRunNamePrefixSuffix: Mono_$(_BuildConfig)
+ extraHelixArguments: /p:BrowserHost=windows
+ scenarios:
+ - normal
+ - wasmtestonbrowser
+ condition: >-
+ or(
+ eq(variables['librariesContainsChange'], true),
+ eq(variables['monoContainsChange'], true),
+ eq(variables['isFullMatrix'], true))
#
# CoreCLR Build for running Apple Silicon libraries-innerloop
jobParameters:
testGroup: innerloop
nameSuffix: AllSubsets_Mono
- buildArgs: -s mono+libs+host+packs+libs.tests -c $(_BuildConfig) /p:ArchiveTests=true
+ buildArgs: -s mono+libs+host+packs+libs.tests -c $(_BuildConfig) /p:ArchiveTests=true $(_runSmokeTestsOnlyArg)
timeoutInMinutes: 180
condition: >-
or(
extraStepsParameters:
creator: dotnet-bot
testRunNamePrefixSuffix: Mono_$(_BuildConfig)
+ extraHelixArguments: $(_runSmokeTestsOnlyArg)
scenarios:
- normal
- wasmtestonbrowser
buildConfig: Release
runtimeFlavor: mono
platforms:
- - Browser_wasm
+ # BuildWasmApps should only happen on the rolling build. No need to duplicate the build on PR's
+ - ${{ if eq(variables['isFullMatrix'], true) }}:
+ - Browser_wasm
variables:
# map dependencies variables to local variables
- name: monoContainsChange
jobParameters:
testGroup: innerloop
nameSuffix: AllSubsets_Mono_EAT
- buildArgs: -s mono+libs+host+packs+libs.tests -c $(_BuildConfig) /p:ArchiveTests=true /p:EnableAggressiveTrimming=true /p:BuildAOTTestsOnHelix=true /p:RunAOTCompilation=false
+ buildArgs: -s mono+libs+host+packs+libs.tests -c $(_BuildConfig) /p:ArchiveTests=true $(_runSmokeTestsOnlyArg) /p:EnableAggressiveTrimming=true /p:BuildAOTTestsOnHelix=true /p:RunAOTCompilation=false
timeoutInMinutes: 180
condition: >-
or(
extraStepsParameters:
creator: dotnet-bot
testRunNamePrefixSuffix: Mono_$(_BuildConfig)
- extraHelixArguments: /p:NeedsToBuildWasmAppsOnHelix=true
+ extraHelixArguments: /p:NeedsToBuildWasmAppsOnHelix=true $(_runSmokeTestsOnlyArg)
scenarios:
- normal
condition: >-
jobParameters:
testGroup: innerloop
nameSuffix: AllSubsets_Mono_AOT
- buildArgs: -s mono+libs+host+packs+libs.tests -c $(_BuildConfig) /p:ArchiveTests=true /p:EnableAggressiveTrimming=true /p:BuildAOTTestsOnHelix=true /p:RunAOTCompilation=true
+ buildArgs: -s mono+libs+host+packs+libs.tests -c $(_BuildConfig) /p:ArchiveTests=true $(_runSmokeTestsOnlyArg) /p:EnableAggressiveTrimming=true /p:BuildAOTTestsOnHelix=true /p:RunAOTCompilation=true
timeoutInMinutes: 180
condition: >-
or(
extraStepsParameters:
creator: dotnet-bot
testRunNamePrefixSuffix: Mono_$(_BuildConfig)
- extraHelixArguments: /p:NeedsToBuildWasmAppsOnHelix=true
+ extraHelixArguments: /p:NeedsToBuildWasmAppsOnHelix=true $(_runSmokeTestsOnlyArg)
scenarios:
- normal
condition: >-
buildArgs: -s mono+libs -c $(_BuildConfig)
timeoutInMinutes: 180
condition: >-
- or(
- eq(dependencies.evaluate_paths.outputs['SetPathVars_runtimetests.containsChange'], true),
- eq(dependencies.evaluate_paths.outputs['SetPathVars_mono.containsChange'], true),
- eq(variables['isFullMatrix'], true))
+ eq(variables['isFullMatrix'], true)
+ # NOTE: Per PR test execution is not recommended for mobile runtime tests
# extra steps, run tests
extraStepsTemplate: /eng/pipelines/common/templates/runtimes/wasm-runtime-and-send-to-helix.yml
extraStepsParameters:
buildArgs: -s mono+libs -c $(_BuildConfig)
timeoutInMinutes: 240
condition: >-
- or(
- eq(dependencies.evaluate_paths.outputs['SetPathVars_runtimetests.containsChange'], true),
- eq(dependencies.evaluate_paths.outputs['SetPathVars_mono.containsChange'], true),
- eq(variables['isFullMatrix'], true))
+ eq(variables['isFullMatrix'], true)
+ # NOTE: Per PR test execution is not recommended for mobile runtime tests
# extra steps, run tests
extraStepsTemplate: /eng/pipelines/common/templates/runtimes/android-runtime-and-send-to-helix.yml
extraStepsParameters:
liveRuntimeBuildConfig: release
runtimeVariant: minijit
condition: >-
- or(
- eq(dependencies.evaluate_paths.outputs['SetPathVars_mono.containsChange'], true),
- eq(dependencies.evaluate_paths.outputs['SetPathVars_runtimetests.containsChange'], true),
- eq(variables['isFullMatrix'], true))
+ eq(variables['isFullMatrix'], true)
#
# Mono CoreCLR runtime Test executions using live libraries in interpreter mode
liveRuntimeBuildConfig: release
runtimeVariant: monointerpreter
condition: >-
- or(
- eq(dependencies.evaluate_paths.outputs['SetPathVars_mono.containsChange'], true),
- eq(dependencies.evaluate_paths.outputs['SetPathVars_runtimetests.containsChange'], true),
- eq(variables['isFullMatrix'], true))
+ eq(variables['isFullMatrix'], true)
#
# Mono CoreCLR runtime Test executions using live libraries and LLVM AOT
# Only when Mono is changed
liveRuntimeBuildConfig: release
runtimeVariant: llvmaot
condition: >-
- or(
- eq(dependencies.evaluate_paths.outputs['SetPathVars_mono.containsChange'], true),
- eq(dependencies.evaluate_paths.outputs['SetPathVars_runtimetests.containsChange'], true),
- eq(variables['isFullMatrix'], true))
+ eq(variables['isFullMatrix'], true)
#
# Mono CoreCLR runtime Test executions using live libraries and LLVM Full AOT
liveRuntimeBuildConfig: release
runtimeVariant: llvmfullaot
condition: >-
- or(
- eq(dependencies.evaluate_paths.outputs['SetPathVars_mono.containsChange'], true),
- eq(dependencies.evaluate_paths.outputs['SetPathVars_runtimetests.containsChange'], true),
- eq(variables['isFullMatrix'], true))
+ eq(variables['isFullMatrix'], true)
#
# Libraries Release Test Execution against a release mono runtime.
or(
eq(dependencies.evaluate_paths.outputs['SetPathVars_coreclr.containsChange'], true),
eq(dependencies.evaluate_paths.outputs['SetPathVars_libraries.containsChange'], true),
- eq(variables['isFullMatrix'], true))
+ eq(variables['isFullMatrix'], true))
\ No newline at end of file
<HelixCorrelationPayload Include="$(MonoTargetsTasksDir)" Destination="build/MonoTargetsTasks" />
</ItemGroup>
- <ItemGroup Condition="'$(TargetOS)' == 'Browser' and '$(Scenario)' != 'BuildWasmApps'">
+ <ItemGroup Condition="'$(TargetOS)' == 'Browser' and '$(RunSmokeTestsOnly)' != 'true' and '$(Scenario)' != 'BuildWasmApps'">
<HelixCorrelationPayload Include="$(TestEchoMiddleware)" Destination="xharness/TestEchoMiddleware" />
<HelixCorrelationPayload Include="$(RemoteLoopMiddleware)" Destination="xharness/RemoteLoopMiddleware" />
</ItemGroup>
<ProjectExclusions Remove="$(MSBuildThisFileDirectory)System.IO.IsolatedStorage\tests\System.IO.IsolatedStorage.Tests.csproj" />
</ItemGroup>
- <ItemGroup>
+ <ItemGroup Condition="'$(RunSmokeTestsOnly)' == 'true'">
+ <ProjectReference Include="$(MSBuildThisFileDirectory)System.Runtime\tests\System.Runtime.Tests.csproj" />
+ </ItemGroup>
+
+ <ItemGroup Condition="'$(RunSmokeTestsOnly)' != 'true'">
<ProjectReference Include="$(MSBuildThisFileDirectory)*\tests\**\*.Tests.csproj"
Exclude="@(ProjectExclusions)"
Condition="'$(TestAssemblies)' == 'true'" />
BuildInParallel="false" />
</ItemGroup>
- <ItemGroup Condition="'$(ArchiveTests)' == 'true' and '$(TargetOS)' == 'Android'">
+ <ItemGroup Condition="'$(ArchiveTests)' == 'true' and '$(RunSmokeTestsOnly)' != 'true' and '$(TargetOS)' == 'Android'">
<ProjectReference Include="$(MonoProjectRoot)sample\Android\AndroidSampleApp.csproj"
BuildInParallel="false" />
<ProjectReference Include="$(RepoRoot)\src\tests\FunctionalTests\Android\**\*.Test.csproj"
</ItemGroup>
<!-- Don't build samples, and functional tests on EAT, AOT, and WBT lanes -->
- <ItemGroup Condition="'$(ArchiveTests)' == 'true' and '$(TargetOS)' == 'Browser' and '$(BuildAOTTestsOnHelix)' != 'true' and '$(TestWasmBuildTests)' != 'true'">
+ <ItemGroup Condition="'$(ArchiveTests)' == 'true' and '$(RunSmokeTestsOnly)' != 'true' and '$(TargetOS)' == 'Browser' and '$(BuildAOTTestsOnHelix)' != 'true' and '$(TestWasmBuildTests)' != 'true'">
<ProjectReference Include="$(MonoProjectRoot)sample\wasm\**\*.Sample.csproj"
Exclude="@(ProjectExclusions)"
BuildInParallel="true" />