public void IsEnabled_forwards_to_NLog_logger(LogLevel level, NLog.LogLevel expected) { var sut = CreateSystemUnderTest(); sut.IsEnabled(level); mockLogger.Verify(p => p.IsEnabled(expected), Times.Once); }
public void Log_levels_are_correctly_converted(LogLevel level, NLog.LogLevel expected) { var sut = CreateSystemUnderTest(); var message = fixture.Create <string>(); IDictionary <string, object> dictionary = new Dictionary <string, object> { ["message"] = message }; sut.Log(level, dictionary, exception: null); mockLogger.Verify(p => p.Log(It.Is <LogEventInfo>(lei => lei.Level == expected)), Times.Once); }