< Summary

Class:SharpHoundCommonLib.NoOpLogger
Assembly:SharpHoundCommonLib
File(s):D:\a\SharpHoundCommon\SharpHoundCommon\src\CommonLib\Logging\NoOpLogger.cs
Covered lines:2
Uncovered lines:6
Coverable lines:8
Total lines:26
Line coverage:25% (2 of 8)
Covered branches:0
Total branches:0

Metrics

MethodBranch coverage Cyclomatic complexity NPath complexity Sequence coverage
Log(...)100%10100%
IsEnabled(...)100%100%
BeginScope(...)100%100%

File(s)

D:\a\SharpHoundCommon\SharpHoundCommon\src\CommonLib\Logging\NoOpLogger.cs

#LineLine coverage
 1using System;
 2using Microsoft.Extensions.Logging;
 3
 4namespace SharpHoundCommonLib
 5{
 6    /// <summary>
 7    ///     An ILogger interface that does nothing
 8    /// </summary>
 9    public class NoOpLogger : ILogger
 10    {
 11        public void Log<TState>(LogLevel logLevel, EventId eventId, TState state, Exception exception,
 12            Func<TState, Exception, string> formatter)
 20813        {
 20814        }
 15
 16        public bool IsEnabled(LogLevel logLevel)
 017        {
 018            return false;
 019        }
 20
 21        public IDisposable BeginScope<TState>(TState state)
 022        {
 023            return default;
 024        }
 25    }
 26}