From fefb90a606f592da2d619672dba8bb43c4904cbf Mon Sep 17 00:00:00 2001 From: Oluwatoni Solarin-Sodara Date: Sat, 1 Sep 2018 19:22:28 +0100 Subject: [PATCH 1/2] upload coverage results to codecov on Ubuntu image --- appveyor.yml | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index 8d53f1fe3..56c28dd8b 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -6,7 +6,13 @@ configuration: - Debug - Release build_script: - - ps: echo "Building for $env:CONFIGURATION" + - ps: echo "Building for $env:CONFIGURATION on $env:APPVEYOR_BUILD_WORKER_IMAGE" - ps: dotnet msbuild build.proj /p:Configuration=$env:CONFIGURATION test_script: - - ps: if ($LastExitCode -ne 0) { $host.SetShouldExit($LastExitCode) } \ No newline at end of file + - ps: if ($LastExitCode -ne 0) { $host.SetShouldExit($LastExitCode) } + - ps: | + if ($env:APPVEYOR_BUILD_WORKER_IMAGE -eq "Ubuntu") { + curl -s https://codecov.io/bash > codecov + chmod +x codecov + ./codecov -f ./test/coverlet.core.tests/coverage.opencover.xml + } From ed9de3d4f2f7874cdcdba1268fcea339cde7b419 Mon Sep 17 00:00:00 2001 From: Oluwatoni Solarin-Sodara Date: Sat, 1 Sep 2018 19:33:46 +0100 Subject: [PATCH 2/2] only upload coverage results when in Release mode --- appveyor.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/appveyor.yml b/appveyor.yml index 56c28dd8b..c65bdfe9c 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -11,7 +11,7 @@ build_script: test_script: - ps: if ($LastExitCode -ne 0) { $host.SetShouldExit($LastExitCode) } - ps: | - if ($env:APPVEYOR_BUILD_WORKER_IMAGE -eq "Ubuntu") { + if ($env:APPVEYOR_BUILD_WORKER_IMAGE -eq "Ubuntu" -and $env:CONFIGURATION -eq "Release") { curl -s https://codecov.io/bash > codecov chmod +x codecov ./codecov -f ./test/coverlet.core.tests/coverage.opencover.xml