public void CleanUp() { if (TestContext.CurrentContext.Result.Outcome.Status != TestStatus.Passed) { Logger.Info($"{AppDomain.CurrentDomain.BaseDirectory}{TestContext.CurrentContext.Test.Name}.jpg"); Browser.WebDriver.TakeScreenshot().SaveAsFile($@"{AppDomain.CurrentDomain.BaseDirectory}{TestContext.CurrentContext.Test.Name}.jpg"); } Browser.Close(); }
public void SetUp() { settings = new TestSettings(); BrowserInit(settings.BrowserName); user = XmlReader.Read <User>("UserData.xml"); Logger.Info($"{TestContext.CurrentContext.Test.Name}" + $"\r\nBrowser:{settings.BrowserName}" + $"\r\nLanguage:{settings.Language}"); }