Beispiel #1
0
 public void TestLessThanLowerLimit()
 {
     var filter = new LevelFilter(LogLevel.Info, LogLevel.Warning);
     var actual = filter.CanLog(new LogEntry { LogLevel = LogLevel.Debug });
     Assert.False(actual);
 }
Beispiel #2
0
 public void TestMoreThanUpperLimit()
 {
     var filter = new LevelFilter(LogLevel.Info, LogLevel.Warning);
     var actual = filter.CanLog(new LogEntry { LogLevel = LogLevel.Error });
     Assert.False(actual);
 }
Beispiel #3
0
 public void TestInRangeUpperLimit()
 {
     var filter = new LevelFilter(LogLevel.Info, LogLevel.Warning);
     var actual = filter.CanLog(new LogEntry { LogLevel = LogLevel.Warning });
     Assert.True(actual);
 }