@@ -62,8 +62,7 @@ install:
6262 Write-Host "Should package Nuget artifact = " -NoNewLine
6363 Write-Host $Env:SHOULD_PACKAGE_NUGET_ARTIFACT -ForegroundColor "Green"
6464
65- $Env:SHOULD_RUN_COVERALLS = $($Env:APPVEYOR_PULL_REQUEST_NUMBER -eq $null `
66- -and $Env:APPVEYOR_SCHEDULED_BUILD -eq $False)
65+ $Env:SHOULD_RUN_COVERALLS = $($Env:APPVEYOR_SCHEDULED_BUILD -eq $True)
6766 Write-Host "Should run Coveralls = " -NoNewLine
6867 Write-Host $Env:SHOULD_RUN_COVERALLS -ForegroundColor "Green"
6968
@@ -109,22 +108,19 @@ build_script:
109108
110109test_script :
111110- ps : |
112- If ($Env:SHOULD_RUN_COVERITY_ANALYSIS -eq $False)
111+ If ($Env:SHOULD_RUN_COVERALLS -eq $True -and $Env:publish_on_success -eq $True)
112+ {
113+ .\packages\OpenCover\OpenCover.Console.exe `
114+ -register:user `
115+ -target:$Env:xunit_runner `
116+ "-targetargs:""$Env:APPVEYOR_BUILD_FOLDER\LibGit2Sharp.Tests\bin\Release\LibGit2Sharp.Tests.dll"" /noshadow /appveyor" `
117+ "-filter:+[LibGit2Sharp]* -[LibGit2Sharp.Tests]*" `
118+ -hideskipped:All `
119+ -output:opencoverCoverage.xml
120+ }
121+ ElseIf ($Env:SHOULD_RUN_COVERITY_ANALYSIS -eq $False)
113122 {
114- If ($Env:SHOULD_RUN_COVERALLS -eq $True -and $Env:publish_on_success -eq $True)
115- {
116- .\packages\OpenCover\OpenCover.Console.exe `
117- -register:user `
118- -target:$Env:xunit_runner `
119- "-targetargs:""$Env:APPVEYOR_BUILD_FOLDER\LibGit2Sharp.Tests\bin\Release\LibGit2Sharp.Tests.dll"" /noshadow /appveyor" `
120- "-filter:+[LibGit2Sharp]* -[LibGit2Sharp.Tests]*" `
121- -hideskipped:All `
122- -output:opencoverCoverage.xml
123- }
124- Else
125- {
126- & "$Env:xunit_runner" "$Env:APPVEYOR_BUILD_FOLDER\LibGit2Sharp.Tests\bin\Release\LibGit2Sharp.Tests.dll" /appveyor
127- }
123+ & "$Env:xunit_runner" "$Env:APPVEYOR_BUILD_FOLDER\LibGit2Sharp.Tests\bin\Release\LibGit2Sharp.Tests.dll" /appveyor
128124 }
129125
130126after_test :
0 commit comments