@@ -128,14 +128,9 @@ task Build {
128128}
129129
130130task Test - If { ! $script :IsUnix } {
131- $testParams = @ {}
132- if ($env: APPVEYOR -ne $null ) {
133- $testParams = @ {" l" = " appveyor" }
134- }
135-
136- exec { & $script :dotnetExe test - c $Configuration @testParams .\test\PowerShellEditorServices.Test\PowerShellEditorServices.Test.csproj }
137- exec { & $script :dotnetExe test - c $Configuration @testParams .\test\PowerShellEditorServices.Test.Protocol\PowerShellEditorServices.Test.Protocol.csproj }
138- exec { & $script :dotnetExe test - c $Configuration @testParams .\test\PowerShellEditorServices.Test.Host\PowerShellEditorServices.Test.Host.csproj }
131+ exec { & $script :dotnetExe test - c $Configuration .\test\PowerShellEditorServices.Test\PowerShellEditorServices.Test.csproj }
132+ exec { & $script :dotnetExe test - c $Configuration .\test\PowerShellEditorServices.Test.Protocol\PowerShellEditorServices.Test.Protocol.csproj }
133+ exec { & $script :dotnetExe test - c $Configuration .\test\PowerShellEditorServices.Test.Host\PowerShellEditorServices.Test.Host.csproj }
139134}
140135
141136task LayoutModule - After Build, BuildHost {
@@ -173,14 +168,20 @@ task UploadArtifacts -If ($script:IsCIBuild) {
173168 }
174169}
175170
176- task UploadTestLogs - If ($script :IsCIBuild ) {
171+ task UploadTestLogs - After Test - If ($script :IsCIBuild ) {
172+ $testLogsPath = " $PSScriptRoot /test/PowerShellEditorServices.Test.Host/bin/$Configuration /net451/logs"
177173 $testLogsZipPath = " $PSScriptRoot /TestLogs.zip"
178174
179- [System.IO.Compression.ZipFile ]::CreateFromDirectory(
180- " $PSScriptRoot /test/PowerShellEditorServices.Test.Host/bin/$Configuration /net451/logs" ,
181- $testLogsZipPath )
175+ if (Test-Path $testLogsPath ) {
176+ [System.IO.Compression.ZipFile ]::CreateFromDirectory(
177+ $testLogsPath ,
178+ $testLogsZipPath )
182179
183- Push-AppveyorArtifact $testLogsZipPath
180+ Push-AppveyorArtifact $testLogsZipPath
181+ }
182+ else {
183+ Write-Host " `n ### WARNING: Test logs could not be found!`n " - ForegroundColor Yellow
184+ }
184185}
185186
186187# The default task is to run the entire CI build
0 commit comments