diff --git a/src/coverlet.core/Coverage.cs b/src/coverlet.core/Coverage.cs index 655c34e..86cb13c 100644 --- a/src/coverlet.core/Coverage.cs +++ b/src/coverlet.core/Coverage.cs @@ -14,17 +14,17 @@ namespace Coverlet.Core { public class Coverage { - private readonly string _module; - private readonly string _identifier; + private string _module; + private string _identifier; private string[] _includeFilters; - private readonly string[] _includeDirectories; + private string[] _includeDirectories; private string[] _excludeFilters; - private readonly string[] _excludedSourceFiles; - private readonly string[] _excludeAttributes; - private readonly bool _singleHit; - private readonly string _mergeWith; - private readonly bool _useSourceLink; - private readonly ILogger _logger; + private string[] _excludedSourceFiles; + private string[] _excludeAttributes; + private bool _singleHit; + private string _mergeWith; + private bool _useSourceLink; + private ILogger _logger; private List _results; public string Identifier @@ -84,7 +84,6 @@ namespace Coverlet.Core } catch (Exception ex) { - // TODO: With verbose logging we should note that instrumentation failed. _logger.LogWarning($"Unable to instrument module: {module} because : {ex.Message}"); InstrumentationHelper.RestoreOriginalModule(module, _identifier); } diff --git a/src/coverlet.msbuild.tasks/MSBuildLogger.cs b/src/coverlet.msbuild.tasks/MSBuildLogger.cs index 2b226a9..2390b62 100644 --- a/src/coverlet.msbuild.tasks/MSBuildLogger.cs +++ b/src/coverlet.msbuild.tasks/MSBuildLogger.cs @@ -9,10 +9,7 @@ namespace Coverlet.MSbuild.Tasks { private readonly TaskLoggingHelper _log; - public MSBuildLogger(TaskLoggingHelper log) - { - _log = log; - } + public MSBuildLogger(TaskLoggingHelper log) => _log = log; public void LogVerbose(string message) => _log.LogMessageFromText(message, MessageImportance.Low);