public void IsEnabled_Tests(string hostJsonContent, string category, LogLevel logLevel, bool expected) { try { FileSystemHelpers.WriteAllTextToFile(_hostJsonFilePath, hostJsonContent); var configuration = Utilities.BuildHostJsonConfigutation(_hostOptions); LoggingFilterHelper loggingFilterHelper = new LoggingFilterHelper(configuration, false); Assert.Equal(expected, loggingFilterHelper.IsEnabled(category, logLevel)); } finally { DeleteIfExists(_workerDir); } }
public bool IsEnabled(LogLevel logLevel) { return(_loggingFilterHelper.IsEnabled(_category, logLevel)); }