@@ -8,6 +8,8 @@ parameters:
88 type : string
99 - name : testVSCodeVersion
1010 type : string
11+ - name : isIntegration
12+ type : string
1113
1214steps :
1315- checkout : self
@@ -33,13 +35,6 @@ steps:
3335 DISPLAY : :99.0
3436 CODE_VERSION : ${{ parameters.testVSCodeVersion }}
3537
36- - powershell : |
37- $tempPath = [System.IO.Path]::GetTempPath()
38- echo "Temp Path: $tempPath"
39- Get-ChildItem -Path $tempPath -Filter *.cpuprofile | Copy-Item -Destination "$(Build.SourcesDirectory)/out/logs"
40- displayName : ' Copy .cpuprofile files to out/logs'
41- condition : succeededOrFailed()
42-
4338- task : PublishTestResults@2
4439 condition : succeededOrFailed()
4540 displayName : ' Publish Test Results'
@@ -51,16 +46,28 @@ steps:
5146 mergeTestResults : true
5247 testRunTitle : $(System.StageDisplayName) $(Agent.JobName) (Attempt $(System.JobAttempt))
5348
49+ - powershell : |
50+ Write-Host "##vso[task.setvariable variable=isIntegrationVar;]${{ parameters.isIntegration }}"
51+ displayName : ' Set IsIntegration Variable'
52+ condition : succeededOrFailed()
53+
54+ - powershell : |
55+ $tempPath = [System.IO.Path]::GetTempPath()
56+ echo "Temp Path: $tempPath"
57+ Get-ChildItem -Path $tempPath -Filter *.cpuprofile | Copy-Item -Destination "$(Build.SourcesDirectory)/out/logs"
58+ displayName : ' Copy .cpuprofile files to out/logs'
59+ condition : eq(variables.isIntegrationVar, true)
60+
5461- ${{ if eq(variables['System.TeamProject'], 'internal') }} :
5562 - task : 1ES.PublishPipelineArtifact@1
56- condition : succeededOrFailed( )
63+ condition : eq(variables.isIntegrationVar, true )
5764 displayName : ' Upload integration test logs'
5865 inputs :
5966 path : ' $(Build.SourcesDirectory)/out/logs'
6067 artifact : ' Test Logs ($(System.StageDisplayName)-$(Agent.JobName)-$(System.JobAttempt))'
6168- ${{ else }} :
6269 - task : PublishPipelineArtifact@1
63- condition : succeededOrFailed( )
70+ condition : eq(variables.isIntegrationVar, true )
6471 displayName : ' Upload integration test logs'
6572 inputs :
6673 targetPath : ' $(Build.SourcesDirectory)/out/logs'
0 commit comments