File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -7,8 +7,18 @@ build_script:
77- pwsh : |
88 Invoke-WebRequest "https://dot.net/v1/dotnet-install.ps1" -OutFile "./dotnet-install.ps1"
99 ./dotnet-install.ps1 -JSonFile global.json -Architecture x64 -InstallDir 'C:\Program Files\dotnet'
10- - dotnet build src --configuration Release
11- - dotnet test src --configuration Release --no-build --no-restore
10+ - pwsh : |
11+ dotnet build src --configuration Release
12+ if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }
13+ dotnet test src --configuration Release --no-build --no-restore --logger trx
14+ $testExit = $LASTEXITCODE
15+ $url = "https://ci.appveyor.com/api/testresults/mstest/$($env:APPVEYOR_JOB_ID)"
16+ Get-ChildItem -Recurse -Filter *.trx | ForEach-Object {
17+ Write-Host "Uploading test results: $($_.FullName)"
18+ try { (New-Object System.Net.WebClient).UploadFile($url, $_.FullName) }
19+ catch { Write-Host "Failed to upload test results: $_" }
20+ }
21+ if ($testExit -ne 0) { exit $testExit }
1222test : off
1323on_failure :
1424 - ps : |
You can’t perform that action at this time.
0 commit comments