From 0f2526168cfb153a1547913436685f1b57e55058 Mon Sep 17 00:00:00 2001 From: Ankit Jain Date: Thu, 29 Aug 2024 19:49:28 -0400 Subject: [PATCH 1/2] [ci] Run tests with the final packages on internal pipeline --- eng/pipelines/templates/BuildAndTest.yml | 64 +++++++++++++----------- 1 file changed, 35 insertions(+), 29 deletions(-) diff --git a/eng/pipelines/templates/BuildAndTest.yml b/eng/pipelines/templates/BuildAndTest.yml index 3abaa7a0486..29c43a09ab2 100644 --- a/eng/pipelines/templates/BuildAndTest.yml +++ b/eng/pipelines/templates/BuildAndTest.yml @@ -21,14 +21,41 @@ parameters: default: false steps: - - script: ${{ parameters.buildScript }} - -restore -build - -pack - -configuration ${{ parameters.buildConfig }} - /p:ArchiveTests=true - /bl:${{ parameters.repoLogPath }}/build.binlog - $(_OfficialBuildIdArgs) - displayName: Build + # Internal pipeline: Build with pack+sign+archive + - ${{ if ne(parameters.runAsPublic, 'true') }}: + - script: ${{ parameters.buildScript }} + -restore -build + -pack + -sign $(_SignArgs) + -publish $(_PublishArgs) + -configuration ${{ parameters.buildConfig }} + /p:ArchiveTests=true + /bl:${{ parameters.repoLogPath }}/build.binlog + $(_OfficialBuildIdArgs) + displayName: Build + + # Public pipeline - helix tests + - ${{ if eq(parameters.runAsPublic, 'true') }}: + - script: ${{ parameters.buildScript }} + -restore -build + -configuration ${{ parameters.buildConfig }} + -pack + /p:ArchiveTests=${{ lower(eq(parameters.runHelixTests, 'true')) }} + /bl:${{ parameters.repoLogPath }}/build.binlog + $(_OfficialBuildIdArgs) + displayName: Build + + # Run on windows, either for internal pipeline, or for public+non-helix-tests job + - ${{ if and(eq(parameters.isWindows, 'true'), or(ne(parameters.runAsPublic, 'true'), ne(parameters.runHelixTests, 'true'))) }}: + - script: ${{ parameters.buildScript }} + -restore -build + -sign $(_SignArgs) + -publish $(_PublishArgs) + -configuration $(_BuildConfig) + /bl:${{ parameters.repoLogPath }}/build-workloads.binlog + -projects eng\workloads\workloads.csproj + $(_InternalBuildArgs) + displayName: Build Workloads - ${{ if or(ne(parameters.runAsPublic, 'true'), ne(parameters.runHelixTests, 'true')) }}: - ${{ if ne(parameters.isWindows, 'true') }}: @@ -124,27 +151,6 @@ steps: # Run on windows, for internal pipeline, or public+non-helix-tests job - ${{ if and(eq(parameters.isWindows, 'true'), or(ne(parameters.runAsPublic, 'true'), ne(parameters.runHelixTests, 'true'))) }}: - - script: ${{ parameters.buildScript }} - -pack - -sign $(_SignArgs) - -publish $(_PublishArgs) - -configuration ${{ parameters.buildConfig }} - /bl:${{ parameters.repoLogPath }}/pack.binlog - /p:Restore=false /p:Build=false - $(_OfficialBuildIdArgs) - displayName: Pack, Sign, and Publish - - - script: ${{ parameters.buildScript }} - -restore -build - -pack - -sign $(_SignArgs) - -publish $(_PublishArgs) - -configuration $(_BuildConfig) - /bl:${{ parameters.repoLogPath }}/build-workloads.binlog - -projects eng\workloads\workloads.csproj - $(_InternalBuildArgs) - displayName: Build Workloads - - ${{ if eq(parameters.runAsPublic, 'true') }}: - task: PublishPipelineArtifact@1 displayName: Publish VSDrop MSIs From 25294c2fca8a9188d17c407c10dd3372b3c8287c Mon Sep 17 00:00:00 2001 From: Ankit Jain Date: Thu, 29 Aug 2024 19:49:45 -0400 Subject: [PATCH 2/2] [tests] Track changes in the packages available in `artifacts` when .. installing the workload for testing. --- tests/Shared/Aspire.Workload.Testing.targets | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/tests/Shared/Aspire.Workload.Testing.targets b/tests/Shared/Aspire.Workload.Testing.targets index 6ad5018dc68..7a48d7a745c 100644 --- a/tests/Shared/Aspire.Workload.Testing.targets +++ b/tests/Shared/Aspire.Workload.Testing.targets @@ -111,10 +111,15 @@ + by the workload installation targets. --> + + - + + + +