From 69ef55ed6694addb012e6bc7c2712fa8ed3f883e Mon Sep 17 00:00:00 2001 From: Santiago Fernandez Madero Date: Tue, 21 Jul 2020 15:41:58 -0700 Subject: [PATCH] Fix libraries outerloop builds (#39735) * Fix libraries outerloop builds * Remove liveRuntimeBuildConfig from all configurations build to not make it wait for coreclr to run --- eng/pipelines/libraries/base-job.yml | 13 +++++++++++++ eng/pipelines/libraries/build-job.yml | 6 ++++++ eng/pipelines/libraries/run-test-job.yml | 13 +------------ eng/pipelines/runtime.yml | 1 - 4 files changed, 20 insertions(+), 13 deletions(-) diff --git a/eng/pipelines/libraries/base-job.yml b/eng/pipelines/libraries/base-job.yml index 99e6271..bf5a9a2 100644 --- a/eng/pipelines/libraries/base-job.yml +++ b/eng/pipelines/libraries/base-job.yml @@ -20,6 +20,7 @@ parameters: testDisplayName: '' testScope: '' pool: '' + runTests: false jobs: - template: /eng/common/templates/job/job.yml @@ -91,6 +92,9 @@ jobs: - ${{ if ne(parameters.liveRuntimeBuildConfig, '') }}: - _runtimeDownloadPath: '$(Build.SourcesDirectory)/artifacts/transport/${{ parameters.runtimeFlavor }}' - _runtimeConfigurationArg: -rc ${{ parameters.liveRuntimeBuildConfig }} + - ${{ if eq(parameters.runTests, true) }}: + - _runtimeArtifactName: '$(runtimeFlavorName)Product_${{ parameters.runtimeVariant}}_${{ parameters.osGroup }}${{ parameters.osSubgroup }}_${{ parameters.archType }}_${{ parameters.liveRuntimeBuildConfig }}' + - _runtimeArtifactsPathArg: ' /p:RuntimeArtifactsPath=$(_runtimeDownloadPath)' - ${{ if eq(parameters.testDisplayName, '') }}: - _testRunNamePrefixSuffix: $(runtimeFlavorName)_${{ parameters.liveRuntimeBuildConfig }} - ${{ if ne(parameters.testDisplayName, '') }}: @@ -121,4 +125,13 @@ jobs: steps: - template: /eng/pipelines/common/clone-checkout-bundle-step.yml + + - ${{ if and(ne(parameters.liveRuntimeBuildConfig, ''), eq(parameters.runTests, true)) }}: + - template: /eng/pipelines/common/download-artifact-step.yml + parameters: + unpackFolder: $(_runtimeDownloadPath) + artifactFileName: '$(_runtimeArtifactName)$(archiveExtension)' + artifactName: '$(_runtimeArtifactName)' + displayName: '$(runtimeFlavorName) build drop' + - ${{ parameters.steps }} diff --git a/eng/pipelines/libraries/build-job.yml b/eng/pipelines/libraries/build-job.yml index f2e8ff2..51dcb37 100644 --- a/eng/pipelines/libraries/build-job.yml +++ b/eng/pipelines/libraries/build-job.yml @@ -41,6 +41,7 @@ jobs: isOfficialAllConfigurations: ${{ parameters.isOfficialAllConfigurations }} liveRuntimeBuildConfig: ${{ parameters.liveRuntimeBuildConfig }} runtimeFlavor: ${{ parameters.runtimeFlavor }} + runTests: ${{ parameters.runTests }} timeoutInMinutes: ${{ parameters.timeoutInMinutes }} preBuildSteps: ${{ parameters.preBuildSteps }} container: ${{ parameters.container }} @@ -51,6 +52,11 @@ jobs: name: build displayName: 'Build' + ${{ if and(ne(parameters.liveRuntimeBuildConfig, ''), eq(parameters.runTests, true)) }}: + dependsOn: + # Use full product dependency for test runs + - ${{ format('{0}_{1}_product_build_{2}{3}_{4}_{5}', parameters.runtimeFlavor, parameters.runtimeVariant, parameters.osGroup, parameters.osSubgroup, parameters.archType, parameters.liveRuntimeBuildConfig) }} + variables: - librariesTestsArtifactName: ${{ format('libraries_test_assets_{0}_{1}_{2}', parameters.osGroup, parameters.archType, parameters.buildConfig) }} - _subset: libs diff --git a/eng/pipelines/libraries/run-test-job.yml b/eng/pipelines/libraries/run-test-job.yml index cf6324e..74bc7da 100644 --- a/eng/pipelines/libraries/run-test-job.yml +++ b/eng/pipelines/libraries/run-test-job.yml @@ -40,6 +40,7 @@ jobs: condition: ${{ parameters.condition }} pool: ${{ parameters.pool }} testScope: ${{ parameters.testScope }} + runTests: true ${{ if ne(parameters.liveRuntimeBuildConfig, '') }}: displayName: ${{ format('Test Run {0} {1}', parameters.liveRuntimeBuildConfig, parameters.runtimeDisplayName) }} name: ${{ format('test_run_{0}_{1}', parameters.liveRuntimeBuildConfig, parameters.runtimeDisplayName) }} @@ -61,10 +62,6 @@ jobs: variables: - librariesTestsArtifactName: ${{ format('libraries_test_assets_{0}_{1}_{2}', parameters.osGroup, parameters.dependsOnTestArchitecture, parameters.dependsOnTestBuildConfiguration) }} - _archiveTestsParameter: /p:ArchiveTests=true - - - ${{ if ne(parameters.liveRuntimeBuildConfig, '') }}: - - _runtimeArtifactName: '$(runtimeFlavorName)Product_${{ parameters.runtimeVariant}}_${{ parameters.osGroup }}${{ parameters.osSubgroup }}_${{ parameters.archType }}_${{ parameters.liveRuntimeBuildConfig }}' - - _runtimeArtifactsPathArg: ' /p:RuntimeArtifactsPath=$(_runtimeDownloadPath)' - ${{ parameters.variables }} @@ -84,14 +81,6 @@ jobs: artifactName: $(librariesTestsArtifactName) artifactFileName: $(librariesTestsArtifactName)$(archiveExtension) unpackFolder: $(Build.SourcesDirectory)/artifacts - - - ${{ if ne(parameters.liveRuntimeBuildConfig, '') }}: - - template: /eng/pipelines/common/download-artifact-step.yml - parameters: - unpackFolder: $(_runtimeDownloadPath) - artifactFileName: '$(_runtimeArtifactName)$(archiveExtension)' - artifactName: '$(_runtimeArtifactName)' - displayName: '$(runtimeFlavorName) build drop' - ${{ if in(parameters.coreclrTestGroup, 'gcstress0x3-gcstress0xc', 'gcstress-extra') }}: # We need to find and download the GC stress dependencies (namely, coredistools). Put them diff --git a/eng/pipelines/runtime.yml b/eng/pipelines/runtime.yml index 6d70e6c..e52318b 100644 --- a/eng/pipelines/runtime.yml +++ b/eng/pipelines/runtime.yml @@ -595,7 +595,6 @@ jobs: isFullMatrix: ${{ variables.isFullMatrix }} framework: allConfigurations runTests: true - liveRuntimeBuildConfig: release condition: >- or( eq(dependencies.checkout.outputs['SetPathVars_libraries.containsChange'], true), -- 2.7.4