public void LogWarning_Foo_WarningAndFoo() { _logger.LogWarning("foo"); MockVsLogger.Verify(l => l.SendMessage( It.Is <TestMessageLevel>(tml => tml == TestMessageLevel.Warning), It.Is <string>(s => s.Contains("Warning") && s.Contains("foo"))), Times.Exactly(1)); }
public void LogError_Foo_ErrorAndFoo() { _logger.LogError("foo"); MockVsLogger.Verify(l => l.SendMessage( It.Is <TestMessageLevel>(tml => tml == TestMessageLevel.Error), It.Is <string>(s => s.Contains("ERROR") && s.Contains("foo"))), Times.Exactly(1)); }
public void LogInfo_Whitespace_NonEmptyString() { _logger.LogInfo("\n"); MockVsLogger.Verify(l => l.SendMessage( It.Is <TestMessageLevel>(tml => tml == TestMessageLevel.Informational), It.Is <string>(s => !string.IsNullOrWhiteSpace(s))), Times.Exactly(1)); }