Skip to content

Commit 0a4bc82

Browse files
committed
code coverage config
1 parent 632341c commit 0a4bc82

2 files changed

Lines changed: 26 additions & 0 deletions

File tree

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
@echo off
2+
3+
4+
cd tests\CodeCoverage
5+
6+
nuget restore packages.config -PackagesDirectory .
7+
8+
cd ..
9+
cd ..
10+
11+
dotnet restore DateTimeAbstractions.sln
12+
rem Clean the solution to force a rebuild with /p:codecov=true
13+
dotnet clean DateTimeAbstractions.sln
14+
15+
rem The -threshold options prevents this taking ages...
16+
tests\CodeCoverage\OpenCover.4.6.519\tools\OpenCover.Console.exe -target:"dotnet.exe" -targetargs:"test tests\Tocsoft.DateTimeAbstractions.Tests\Tocsoft.DateTimeAbstractions.Tests.csproj -c Release /p:codecov=true" -register:user -threshold:10 -oldStyle -safemode:off -output:.\Tocsoft.DateTimeAbstractions.Coverage.xml -hideskipped:All -returntargetcode -filter:"+[Tocsoft.DateTimeAbstractions*]*"
17+
18+
if %errorlevel% neq 0 exit /b %errorlevel%
19+
20+
SET PATH=C:\\Python34;C:\\Python34\\Scripts;%PATH%
21+
pip install codecov
22+
codecov -f "Tocsoft.DateTimeAbstractions.Coverage.xml"

tests/CodeCoverage/packages.config

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<packages>
3+
<package id="OpenCover" version="4.6.519" />
4+
</packages>

0 commit comments

Comments
 (0)