From 33141b3fc06d2059f63501d72e455a499be08a13 Mon Sep 17 00:00:00 2001 From: Justin Anderson Date: Tue, 22 Jun 2021 13:30:02 -0700 Subject: [PATCH] Collect hang dumps --- eng/Versions.props | 3 +++ eng/build.yml | 22 ++++++++++++++++++++-- src/Directory.Build.props | 4 ++++ 3 files changed, 27 insertions(+), 2 deletions(-) diff --git a/eng/Versions.props b/eng/Versions.props index 7037e163bd..8b11b44c39 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -31,6 +31,9 @@ true 3.0.0 + + true + 16.10.0 5.0.0 4.3.0 diff --git a/eng/build.yml b/eng/build.yml index 65fd1d5f16..02334497de 100644 --- a/eng/build.yml +++ b/eng/build.yml @@ -213,8 +213,8 @@ jobs: # Publish test results to Azure Pipelines - task: PublishTestResults@2 inputs: - testResultsFormat: xUnit - testResultsFiles: '**/*UnitTests*.xml' + testResultsFormat: VSTest + testResultsFiles: '**/*UnitTests*.trx' searchFolder: '$(Build.SourcesDirectory)/artifacts/TestResults' failTaskOnFailedTests: true testRunTitle: 'Tests $(_PhaseName) $(_BuildArch) $(_BuildConfig)' @@ -223,3 +223,21 @@ jobs: buildConfiguration: ${{ parameters.name }} continueOnError: true condition: ne(variables['_BuildOnly'], 'true') + + - task: CopyFiles@2 + displayName: Gather Test Dumps + inputs: + sourceFolder: '$(Build.SourcesDirectory)/artifacts/TestResults' + contents: '**/*.dmp' + targetFolder: '$(Build.StagingDirectory)/TestDumps' + continueOnError: true + condition: failed() + + - task: PublishBuildArtifacts@1 + displayName: Publish Test Dumps + inputs: + PathtoPublish: '$(Build.StagingDirectory)/TestDumps' + PublishLocation: Container + ArtifactName: TestDumps_$(_PhaseName)_$(_BuildArch)_$(_BuildConfig) + continueOnError: true + condition: failed() diff --git a/src/Directory.Build.props b/src/Directory.Build.props index 7dfea314a2..525f588e8d 100644 --- a/src/Directory.Build.props +++ b/src/Directory.Build.props @@ -27,6 +27,10 @@ portable + + --blame "CollectHangDump;TestTimeout=5m" + +