Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 13 additions & 7 deletions eng/pipelines/common/templates/browser-wasm-build-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ parameters:
platforms: []
shouldContinueOnError: false
extraBuildArgs: ''
# When true, these WBT jobs run in a dedicated 'WasmBuildTests' stage that
# depends on the 'Build' stage. In that case the cross-job 'dependsOn' on the
# build-only producer jobs must be dropped (job dependencies are stage-scoped);
# the producer artifacts are still fetched via DownloadBuildArtifacts@0.
separateStage: false

jobs:

Expand Down Expand Up @@ -40,13 +45,14 @@ jobs:
value: $(shouldRunWasmBuildTestsOnDefaultPipeline)

jobParameters:
dependsOn:
- ${{ if eq(platform, 'browser_wasm') }}:
- build_browser_wasm_linux_Release_MultiThreaded_BuildOnly
- build_browser_wasm_linux_Release_SingleThreaded_BuildOnly
- ${{ if eq(platform, 'browser_wasm_win') }}:
- build_browser_wasm_windows_Release_MultiThreaded_BuildOnly
- build_browser_wasm_windows_Release_SingleThreaded_BuildOnly
${{ if ne(parameters.separateStage, true) }}:
dependsOn:
- ${{ if eq(platform, 'browser_wasm') }}:
- build_browser_wasm_linux_Release_MultiThreaded_BuildOnly
- build_browser_wasm_linux_Release_SingleThreaded_BuildOnly
- ${{ if eq(platform, 'browser_wasm_win') }}:
- build_browser_wasm_windows_Release_MultiThreaded_BuildOnly
- build_browser_wasm_windows_Release_SingleThreaded_BuildOnly
isExtraPlatforms: ${{ parameters.isExtraPlatformsBuild }}
testGroup: innerloop
nameSuffix: WasmBuildTests
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ parameters:
platforms: []
shouldContinueOnError: false
extraBuildArgs: ''
# When true, these WBT jobs run in a dedicated 'WasmBuildTests' stage that
# depends on the 'Build' stage. In that case the cross-job 'dependsOn' on the
# build-only producer jobs must be dropped (job dependencies are stage-scoped);
# the producer artifacts are still fetched via DownloadBuildArtifacts@0.
separateStage: false

jobs:

Expand Down Expand Up @@ -40,11 +45,12 @@ jobs:
value: $(shouldRunWasmBuildTestsOnDefaultPipeline)

jobParameters:
dependsOn:
- ${{ if eq(platform, 'browser_wasm') }}:
- build_browser_wasm_linux_Release_CoreCLR
- ${{ if eq(platform, 'browser_wasm_win') }}:
- build_browser_wasm_windows_Release_CoreCLR
${{ if ne(parameters.separateStage, true) }}:
dependsOn:
- ${{ if eq(platform, 'browser_wasm') }}:
- build_browser_wasm_linux_Release_CoreCLR
- ${{ if eq(platform, 'browser_wasm_win') }}:
- build_browser_wasm_windows_Release_CoreCLR
isExtraPlatforms: ${{ parameters.isExtraPlatformsBuild }}
testGroup: innerloop
nameSuffix: CoreCLR_WasmBuildTests
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# Emits a dedicated 'WasmBuildTests' stage that runs Wasm.Build.Tests (WBT) for
# the extra-platforms wasm pipelines (runtime-wasm, runtime-wasm-non-libtests).
#
# The build-only producer jobs (wasm-build-only.yml) remain in the 'Build' stage
# emitted by runtime-extra-platforms-wasm.yml. This stage depends on 'Build',
# consumes the producers' published artifacts, and runs the WBT suite. It also
# depends on 'EvaluatePaths' (on PRs) because the WBT job conditions consume
# path-evaluation variables (shouldRunWasmBuildTestsOnDefaultPipeline, etc.).
#
# The stage is only emitted when WBT would actually run, mirroring the guard used
# for the WBT jobs in runtime-extra-platforms-wasm.yml, so pipelines that exclude
# WBT don't produce an empty stage.
parameters:
isExtraPlatformsBuild: false
isWasmOnlyBuild: false
isRollingBuild: false
excludeNonLibTests: false
debuggerTestsOnly: false
dependsOn:
- Build

stages:
- ${{ if and(ne(parameters.isRollingBuild, true), ne(parameters.excludeNonLibTests, true), ne(parameters.debuggerTestsOnly, true)) }}:
- stage: WasmBuildTests
displayName: Wasm.Build.Tests
dependsOn:
- ${{ each stage in parameters.dependsOn }}:
- ${{ stage }}
- ${{ if eq(variables['Build.Reason'], 'PullRequest') }}:
- EvaluatePaths
jobs:
# Browser Wasm.Build.Tests (Mono)
- template: /eng/pipelines/common/templates/browser-wasm-build-tests.yml
parameters:
separateStage: true
platforms:
- browser_wasm
- browser_wasm_win
extraBuildArgs: /p:AotHostArchitecture=x64 /p:AotHostOS=$(_hostedOS)

# WASI Wasm.Build.Tests (single-threaded)
- template: /eng/pipelines/common/templates/simple-wasm-build-tests.yml
parameters:
platforms:
- wasi_wasm
- wasi_wasm_win
extraBuildArgs: /p:AotHostArchitecture=x64 /p:AotHostOS=$(_hostedOS)
isExtraPlatformsBuild: ${{ parameters.isExtraPlatformsBuild }}
isWasmOnlyBuild: ${{ parameters.isWasmOnlyBuild }}
20 changes: 4 additions & 16 deletions eng/pipelines/extra-platforms/runtime-extra-platforms-wasm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -187,22 +187,10 @@ jobs:
publishArtifactsForWorkload: true
publishWBT: false

# Browser Wasm.Build.Tests
- template: /eng/pipelines/common/templates/browser-wasm-build-tests.yml
parameters:
platforms:
- browser_wasm
- browser_wasm_win
extraBuildArgs: /p:AotHostArchitecture=x64 /p:AotHostOS=$(_hostedOS)

- template: /eng/pipelines/common/templates/simple-wasm-build-tests.yml
parameters:
platforms:
- wasi_wasm
- wasi_wasm_win
extraBuildArgs: /p:AotHostArchitecture=x64 /p:AotHostOS=$(_hostedOS)
isExtraPlatformsBuild: ${{ parameters.isExtraPlatformsBuild }}
isWasmOnlyBuild: ${{ parameters.isWasmOnlyBuild }}
# Note: Wasm.Build.Tests (browser + wasi) run in a dedicated 'WasmBuildTests'
# stage emitted by runtime-extra-platforms-wasm-build-tests.yml. The build-only
# producer jobs above stay in the 'Build' stage and publish artifacts the WBT
# stage consumes.

- template: /eng/pipelines/common/templates/wasm-runtime-tests.yml
parameters:
Expand Down
7 changes: 7 additions & 0 deletions eng/pipelines/runtime-wasm-non-libtests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,10 @@ extends:
isRollingBuild: ${{ variables.isRollingBuild }}
excludeNonLibTests: false
excludeLibTests: true

- template: /eng/pipelines/extra-platforms/runtime-extra-platforms-wasm-build-tests.yml
parameters:
isExtraPlatformsBuild: ${{ variables.isExtraPlatformsBuild }}
isWasmOnlyBuild: ${{ variables.isWasmOnlyBuild }}
isRollingBuild: ${{ variables.isRollingBuild }}
excludeNonLibTests: false
6 changes: 6 additions & 0 deletions eng/pipelines/runtime-wasm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,9 @@ extends:
isWasmOnlyBuild: ${{ variables.isWasmOnlyBuild }}
isRollingBuild: ${{ variables.isRollingBuild }}
excludeOptional: false

- template: /eng/pipelines/extra-platforms/runtime-extra-platforms-wasm-build-tests.yml
parameters:
isExtraPlatformsBuild: ${{ variables.isExtraPlatformsBuild }}
isWasmOnlyBuild: ${{ variables.isWasmOnlyBuild }}
isRollingBuild: ${{ variables.isRollingBuild }}
50 changes: 32 additions & 18 deletions eng/pipelines/runtime.yml
Original file line number Diff line number Diff line change
Expand Up @@ -259,15 +259,6 @@ extends:
eq(stageDependencies.EvaluatePaths.evaluate_paths.outputs['SetPathVars_wasm_coreclr_runtimetests.containsChange'], true),
eq(variables['isRollingBuild'], true))

# Browser Wasm.Build.Tests
- template: /eng/pipelines/common/templates/browser-wasm-coreclr-build-tests.yml
parameters:
platforms:
- browser_wasm
- browser_wasm_win
alwaysRun: ${{ variables.isRollingBuild }}
extraBuildArgs: /p:AotHostArchitecture=x64 /p:AotHostOS=$(_hostedOS)

#
# Build CoreCLR and Libraries with Libraries tests
# For running libraries tests and installer tests
Expand Down Expand Up @@ -1082,15 +1073,6 @@ extends:
publishArtifactsForWorkload: true
publishWBT: false

# Browser Wasm.Build.Tests
- template: /eng/pipelines/common/templates/browser-wasm-build-tests.yml
parameters:
platforms:
- browser_wasm
- browser_wasm_win
alwaysRun: ${{ variables.isRollingBuild }}
extraBuildArgs: /p:AotHostArchitecture=x64 /p:AotHostOS=$(_hostedOS)

# Wasm runtime tests
- template: /eng/pipelines/common/templates/wasm-runtime-tests.yml
parameters:
Expand Down Expand Up @@ -2003,3 +1985,35 @@ extends:
eq(stageDependencies.EvaluatePaths.evaluate_paths.outputs['SetPathVars_libraries.containsChange'], true),
eq(stageDependencies.EvaluatePaths.evaluate_paths.outputs['SetPathVars_mono_excluding_wasm.containsChange'], true),
eq(variables['isRollingBuild'], true))

# Dedicated stage for Wasm.Build.Tests (WBT).
# The producer runtime/build jobs remain in the 'Build' stage above; these
# WBT jobs depend on that stage, consume its published artifacts, and run the
# Wasm.Build.Tests suite. The stage also depends on 'EvaluatePaths' (on PRs)
# because the WBT job conditions consume path-evaluation variables.
- stage: WasmBuildTests
displayName: Wasm.Build.Tests
dependsOn:
- Build
- ${{ if eq(variables['Build.Reason'], 'PullRequest') }}:
- EvaluatePaths
jobs:
# Browser Wasm.Build.Tests (CoreCLR)
- template: /eng/pipelines/common/templates/browser-wasm-coreclr-build-tests.yml
parameters:
separateStage: true
platforms:
- browser_wasm
- browser_wasm_win
alwaysRun: ${{ variables.isRollingBuild }}
extraBuildArgs: /p:AotHostArchitecture=x64 /p:AotHostOS=$(_hostedOS)

# Browser Wasm.Build.Tests (Mono)
- template: /eng/pipelines/common/templates/browser-wasm-build-tests.yml
parameters:
separateStage: true
platforms:
- browser_wasm
- browser_wasm_win
alwaysRun: ${{ variables.isRollingBuild }}
extraBuildArgs: /p:AotHostArchitecture=x64 /p:AotHostOS=$(_hostedOS)
Loading