Merge pull request #406 from MarcoRossignoli/downgradelog

Downgrade verbosity log for hit files not found
This commit is contained in:
Toni Solarin-Sodara
2019-05-12 23:50:53 +01:00
committed by GitHub
2 changed files with 6 additions and 2 deletions
+1 -1
View File
@@ -24,7 +24,7 @@
</Target>
<Target Name="RunTests" AfterTargets="CopyMSBuildScripts">
<Exec Command="dotnet test &quot;$(MSBuildThisFileDirectory)test\coverlet.core.tests\coverlet.core.tests.csproj&quot; -c $(Configuration) /p:CollectCoverage=true /p:CoverletOutputFormat=opencover /p:Include=[coverlet.*]* -verbosity:minimal"/>
<Exec Command="dotnet test &quot;$(MSBuildThisFileDirectory)test\coverlet.core.tests\coverlet.core.tests.csproj&quot; -c $(Configuration) /p:CollectCoverage=true /p:CoverletOutputFormat=opencover /p:Include=[coverlet.*]*"/>
</Target>
<Target Name="CreateNuGetPackage" AfterTargets="RunTests" Condition="$(Configuration) == 'Release'">
+5 -1
View File
@@ -209,7 +209,11 @@ namespace Coverlet.Core
{
if (!File.Exists(result.HitsFilePath))
{
_logger.LogWarning($"Hits file:'{result.HitsFilePath}' not found for module: '{result.Module}'");
// Hits file could be missed mainly for two reason
// 1) Issue during module Unload()
// 2) Instrumented module is never loaded or used so we don't have any hit to register and
// module tracker is never used
_logger.LogVerbose($"Hits file:'{result.HitsFilePath}' not found for module: '{result.Module}'");
continue;
}