/// <summary> /// Provides re-try logic, logging mechanism, screenshot storing and other basic functionality of Selenium tests. /// </summary> public SeleniumTestBase() { if (SeleniumTestsConfiguration.TestContextLogger) { var logger = Loggers.FirstOrDefault(s => s is TestContextLogger); Loggers.Remove(logger); Loggers.Add(new TestContextLogger(this)); } }
public ILogger GetDefault() { //Just looks for a default log type and attempts to construct it. try { var logEntry = Loggers.FirstOrDefault(x => x.Enabled); return(logEntry.Construct()); } catch (Exception ex) { //can't construct Debug.Print(ex.ToString()); return(new NullLogger()); } }