Skip to content

Commit 33affd6

Browse files
committed
update documentation
1 parent 17edaee commit 33affd6

File tree

9 files changed

+48
-46
lines changed

9 files changed

+48
-46
lines changed

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -303,4 +303,6 @@ __pycache__/
303303
.AssemblyAttributes
304304
DeterministicTest.props
305305
test/coverlet.integration.determisticbuild/*.txt
306-
test/coverlet.integration.determisticbuild/runsettings
306+
test/coverlet.integration.determisticbuild/runsettings
307+
308+
coverage.cobertura.xml

Documentation/Examples/MSBuild/DeterministicBuild/HowTo.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -37,17 +37,17 @@ Add msbuild package version generated to `"..\Documentation\Examples\MSBuild\Det
3737
<Project Sdk="Microsoft.NET.Sdk">
3838

3939
<PropertyGroup>
40-
<TargetFramework>netcoreapp3.1</TargetFramework>
40+
<TargetFramework>net6.0</TargetFramework>
4141
<IsPackable>false</IsPackable>
4242
</PropertyGroup>
4343

4444
<ItemGroup>
45-
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.5.0" />
46-
<PackageReference Include="xunit" Version="2.4.0" />
47-
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.0" />
48-
<PackageReference Include="coverlet.collector" Version="1.2.0" />
49-
<!-- version comes from coverlet.msbuild.2.9.0-preview.6.ga0e22ec622.nupkg -->
50-
<PackageReference Include="coverlet.msbuild" Version="2.9.0-preview.6.ga0e22ec622" >
45+
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.5.0" />
46+
<PackageReference Include="xunit" Version="2.5.0" />
47+
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.0" />
48+
<PackageReference Include="coverlet.collector" Version="6.0.0" />
49+
<!-- version comes from coverlet.msbuild.6.0.1-preview.8.gcb9b802a5f.nupkg -->
50+
<PackageReference Include="coverlet.msbuild" Version="coverlet.msbuild.6.0.1-preview.8.gcb9b802a5f.nupkg" >
5151
<PrivateAssets>all</PrivateAssets>
5252
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
5353
</PackageReference>
@@ -65,7 +65,7 @@ Go to test project folder and run
6565
C:\git\coverlet\Documentation\Examples\MSBuild\DeterministicBuild (detbuilddocs -> origin)
6666
λ dotnet test /p:CollectCoverage=true /p:DeterministicSourcePaths=true
6767
Test run for C:\git\coverlet\Documentation\Examples\MSBuild\DeterministicBuild\XUnitTestProject1\bin\Debug\netcoreapp3.1\XUnitTestProject1.dll(.NETCoreApp,Version=v3.1)
68-
Microsoft (R) Test Execution Command Line Tool Version 16.5.0
68+
Microsoft (R) Test Execution Command Line Tool Version 17.5.0
6969
Copyright (c) Microsoft Corporation. All rights reserved.
7070
7171
Starting test execution, please wait...
@@ -98,4 +98,4 @@ You should see on output folder the coverlet source root mapping file generated.
9898
This is the confirmation that you're running coverage on deterministic build.
9999
```
100100
Documentation\Examples\MSBuild\DeterministicBuild\XUnitTestProject1\bin\Debug\netcoreapp3.1\CoverletSourceRootsMapping
101-
```
101+
```

Documentation/Examples/MSBuild/DeterministicBuild/XUnitTestProject1/XUnitTestProject1.csproj

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>netcoreapp3.1</TargetFramework>
4+
<TargetFramework>net6.0</TargetFramework>
55
<IsPackable>false</IsPackable>
66
</PropertyGroup>
77

88
<ItemGroup>
9-
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.5.0" />
10-
<PackageReference Include="xunit" Version="2.4.0" />
11-
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.0" />
12-
<PackageReference Include="coverlet.collector" Version="1.2.0" />
9+
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.5.0" />
10+
<PackageReference Include="xunit" Version="2.5.0" />
11+
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.0" />
12+
<PackageReference Include="coverlet.collector" Version="6.0.0" />
1313
<PackageReference Include="coverlet.msbuild" Version="ADD VERSION FROM bin\Debug\Packages generated running 'dotnet pack' from repo root" >
1414
<PrivateAssets>all</PrivateAssets>
1515
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>

Documentation/Examples/MSBuild/MergeWith/XUnitTestProject1/XUnitTestProject1.csproj

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>netcoreapp3.1</TargetFramework>
4+
<TargetFramework>net6.0</TargetFramework>
55
<IsPackable>false</IsPackable>
66
</PropertyGroup>
77

88
<ItemGroup>
9-
<PackageReference Include="coverlet.msbuild" Version="2.8.0">
9+
<PackageReference Include="coverlet.msbuild" Version="6.0.0">
1010
<PrivateAssets>all</PrivateAssets>
1111
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
1212
</PackageReference>
13-
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.5.0" />
14-
<PackageReference Include="xunit" Version="2.4.0" />
15-
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.0" />
13+
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.5.0" />
14+
<PackageReference Include="xunit" Version="2.5.0" />
15+
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.0" />
1616
</ItemGroup>
1717

1818
<ItemGroup>

Documentation/Examples/MSBuild/MergeWith/XUnitTestProject2/XUnitTestProject2.csproj

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>netcoreapp3.1</TargetFramework>
4+
<TargetFramework>net6.0</TargetFramework>
55
<IsPackable>false</IsPackable>
66
</PropertyGroup>
77

88
<ItemGroup>
9-
<PackageReference Include="coverlet.msbuild" Version="2.8.0">
9+
<PackageReference Include="coverlet.msbuild" Version="6.0.0">
1010
<PrivateAssets>all</PrivateAssets>
1111
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
1212
</PackageReference>
13-
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.5.0" />
14-
<PackageReference Include="xunit" Version="2.4.0" />
15-
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.0" />
13+
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.5.0" />
14+
<PackageReference Include="xunit" Version="2.5.0" />
15+
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.0" />
1616
</ItemGroup>
1717

1818
<ItemGroup>

Documentation/Examples/MSBuild/MergeWith/XUnitTestProject3/XUnitTestProject3.csproj

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>netcoreapp3.1</TargetFramework>
4+
<TargetFramework>net6.0</TargetFramework>
55
<IsPackable>false</IsPackable>
66
</PropertyGroup>
77

88
<ItemGroup>
9-
<PackageReference Include="coverlet.msbuild" Version="2.8.0">
9+
<PackageReference Include="coverlet.msbuild" Version="6.0.0">
1010
<PrivateAssets>all</PrivateAssets>
1111
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
1212
</PackageReference>
13-
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.5.0" />
14-
<PackageReference Include="xunit" Version="2.4.0" />
15-
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.0" />
13+
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.5.0" />
14+
<PackageReference Include="xunit" Version="2.5.0" />
15+
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.0" />
1616
</ItemGroup>
1717

1818
<ItemGroup>

Documentation/Examples/VSTest/DeterministicBuild/HowTo.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -37,16 +37,16 @@ Add collectors package version generated to `"..\Documentation\Examples\VSTest\D
3737
<Project Sdk="Microsoft.NET.Sdk">
3838

3939
<PropertyGroup>
40-
<TargetFramework>netcoreapp3.1</TargetFramework>
40+
<TargetFramework>net6.0</TargetFramework>
4141
<IsPackable>false</IsPackable>
4242
</PropertyGroup>
4343

4444
<ItemGroup>
45-
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.5.0" />
46-
<PackageReference Include="xunit" Version="2.4.0" />
47-
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.0" />
48-
<!-- version comes from coverlet.collector.1.3.0-preview.6.ga0e22ec622.snupkg -->
49-
<PackageReference Include="coverlet.collector" Version="1.3.0-preview.6.ga0e22ec622" />
45+
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.5.0" />
46+
<PackageReference Include="xunit" Version="2.5.0" />
47+
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.0" />
48+
<!-- version comes from coverlet.coverlet.collector.6.0.1-preview.8.gcb9b802a5f.snupkg -->
49+
<PackageReference Include="coverlet.collector.6.0.1-preview.8.gcb9b802a5f.nupkg" />
5050
</ItemGroup>
5151

5252
<ItemGroup>
@@ -79,4 +79,4 @@ You should see on output folder the coverlet source root mapping file generated.
7979
This is the confirmation that you're running coverage on deterministic build.
8080
```
8181
Documentation\Examples\VSTest\DeterministicBuild\XUnitTestProject1\bin\Debug\netcoreapp3.1\CoverletSourceRootsMapping_XUnitTestProject1
82-
```
82+
```

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ See [documentation](Documentation/VSTestIntegration.md) for advanced usage.
6060
* _You need to be running .NET Core SDK v2.2.401 or newer_
6161
* _You need to reference version 16.5.0 and above of Microsoft.NET.Test.Sdk_
6262
```
63-
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.5.0" />
63+
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.5.0" />
6464
```
6565

6666
### MSBuild Integration (suffers of possible [known issue](https://github.com/coverlet-coverage/coverlet/blob/master/Documentation/KnownIssues.md#1-vstest-stops-process-execution-earlydotnet-test))

test/coverlet.integration.tests/DeterministicBuild.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ public void Msbuild()
8888
Assert.True(File.Exists(Path.Combine(_testProjectPath, "coverage.json")));
8989
AssertCoverage(standardOutput);
9090

91-
// Process exits hang on clean seem that process doesn't close, maybe some mbuild node reuse? btw manually tested
91+
// Process exits hang on clean seem that process doesn't close, maybe some msbuild node reuse? btw manually tested
9292
// DotnetCli("clean", out standardOutput, out standardError, _fixture.TestProjectPath);
9393
// Assert.False(File.Exists(sourceRootMappingFilePath));
9494
RunCommand("git", "clean -fdx", out _, out _, _testProjectPath);
@@ -112,7 +112,7 @@ public void Msbuild_SourceLink()
112112
Assert.Contains("raw.githubusercontent.com", File.ReadAllText(Path.Combine(_testProjectPath, "coverage.json")));
113113
AssertCoverage(standardOutput, checkDeterministicReport: false);
114114

115-
// Process exits hang on clean seem that process doesn't close, maybe some mbuild node reuse? btw manually tested
115+
// Process exits hang on clean seem that process doesn't close, maybe some msbuild node reuse? btw manually tested
116116
// DotnetCli("clean", out standardOutput, out standardError, _fixture.TestProjectPath);
117117
// Assert.False(File.Exists(sourceRootMappingFilePath));
118118
RunCommand("git", "clean -fdx", out _, out _, _testProjectPath);
@@ -140,7 +140,7 @@ public void Collectors()
140140
Assert.Contains("[coverlet]Initialize CoverletInProcDataCollector", File.ReadAllText(Directory.GetFiles(_testProjectPath, "log.host.*.txt").Single()));
141141
Assert.Contains("[coverlet]Mapping resolved", dataCollectorLogContent);
142142

143-
// Process exits hang on clean seem that process doesn't close, maybe some mbuild node reuse? btw manually tested
143+
// Process exits hang on clean seem that process doesn't close, maybe some msbuild node reuse? btw manually tested
144144
// DotnetCli("clean", out standardOutput, out standardError, _fixture.TestProjectPath);
145145
// Assert.False(File.Exists(sourceRootMappingFilePath));
146146
RunCommand("git", "clean -fdx", out _, out _, _testProjectPath);
@@ -169,7 +169,7 @@ public void Collectors_SourceLink()
169169
Assert.Contains("[coverlet]Initialize CoverletInProcDataCollector", File.ReadAllText(Directory.GetFiles(_testProjectPath, "log.host.*.txt").Single()));
170170
Assert.Contains("[coverlet]Mapping resolved", dataCollectorLogContent);
171171

172-
// Process exits hang on clean seem that process doesn't close, maybe some mbuild node reuse? btw manually tested
172+
// Process exits hang on clean seem that process doesn't close, maybe some msbuild node reuse? btw manually tested
173173
// DotnetCli("clean", out standardOutput, out standardError, _fixture.TestProjectPath);
174174
// Assert.False(File.Exists(sourceRootMappingFilePath));
175175
RunCommand("git", "clean -fdx", out _, out _, _testProjectPath);

0 commit comments

Comments
 (0)