Insert the pre-release nuget feed before building test artifacts (#18507)

This commit is contained in:
Travis Plunk 2022-11-09 14:37:13 -08:00 committed by GitHub
parent fe76300a5f
commit 67135b47d7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 15 additions and 1 deletions

View File

@ -1140,7 +1140,16 @@ function Publish-PSTestTools {
$runtime = $Options.Runtime
}
dotnet publish --output bin --configuration $Options.Configuration --framework $Options.Framework --runtime $runtime --self-contained
Write-Verbose -Verbose -Message "Starting dotnet publish for $toolPath with runtime $runtime"
dotnet publish --output bin --configuration $Options.Configuration --framework $Options.Framework --runtime $runtime --self-contained | Out-String | Write-Verbose -Verbose
$dll = $null
$dll = Get-ChildItem -Path bin -Recurse -Filter "*.dll"
if (-not $dll) {
throw "Failed to find exe in $toolPath"
}
if ( -not $env:PATH.Contains($toolPath) ) {
$env:PATH = $toolPath+$TestModulePathSeparator+$($env:PATH)

View File

@ -14,6 +14,10 @@ jobs:
- checkout: self
clean: true
- template: /tools/releaseBuild/azureDevOps/templates/insert-nuget-config-azfeed.yml
parameters:
repoRoot: $(Build.SourcesDirectory)
- pwsh: |
Import-Module ./build.psm1
Start-PSBootstrap
@ -59,5 +63,6 @@ jobs:
BuildTestPackage -runtime linux-musl-x64
displayName: Build test package and upload
retryCountOnTaskFailure: 1
- template: /tools/releaseBuild/azureDevOps/templates/step/finalize.yml