Skip to content

Commit b36b671

Browse files
authored
add hints in documentation (#1674)
1 parent fae5c40 commit b36b671

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

Documentation/GlobalTool.md

+3
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,9 @@ coverlet <ASSEMBLY> --target <TARGET> --targetargs <TARGETARGS> --output "/custo
114114

115115
The above command will write the results to the supplied path, if no file extension is specified it'll use the standard extension of the selected output format. To specify a directory instead, simply append a `/` to the end of the value.
116116

117+
>[!TIP]
118+
>Use only folder name whenever multiple coverage output formats are used.
119+
117120
```bash
118121
coverlet <ASSEMBLY> --target <TARGET> --targetargs <TARGETARGS> --output "/custom/directory/" -f json -f lcov
119122
```

Documentation/VSTestIntegration.md

+11-1
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,17 @@ You can change the output directory using the standard `dotnet test` switch `--r
7070

7171
:warning:At the moment VSTest integration **doesn't support all features** of msbuild and .NET tool, for instance show result on console, report merging and threshold validation.
7272
We're working to fill the gaps.
73-
>*PS: if you don't have any other way to merge reports(for instance your report generator doesn't support multi coverage file) you can for the moment exploit a trick reported by one of our contributor Daniel Paz(@p4p3) <https://github.com/tonerdo/coverlet/pull/225#issuecomment-573896446>*
73+
74+
> [!TIP]
75+
> *Some alternative solutions to merge coverage files*
76+
>
77+
> * use _dotnet-coverage_ tool and merge multiple coverage files
78+
>
79+
> `dotnet-coverage merge artifacts/coverage/**/coverage.cobertura.xml -f cobertura -o artifacts/coverage/coverage.xml`*
80+
>
81+
> * use _dotnet-reportgenerator-globaltool_ to create a HTML report and a merged coverage file
82+
>
83+
> `reportgenerator -reports:"**/*.cobertura.xml" -targetdir:"artifacts\reports.cobertura" -reporttypes:"HtmlInline_AzurePipelines_Dark;Cobertura"`
7484
7585
### Default option (if you don't specify a runsettings file)
7686

0 commit comments

Comments
 (0)