public void CheckRecurringPayment() { List <dynamic> sites = ReadCSV.GetSites("Cases/RecurringPayment/CheckRecurringPaymentTestData.csv"); IWebDriver driver = StartUp(); try { for (int j = 0; j < sites.Count; j++) { try { BasicLogin.Execute(sites[j], driver); RecurringPayment.Execute(sites[j], driver); } catch (System.Exception ex) { throw ex; } finally { foreach (KeyValuePair <string, object> entry in sites[j]) { TestContext.WriteLine(entry.Key + ": " + entry.Value); } } } } catch (System.Exception ex) { throw ex; } finally { driver.Close(); driver.Dispose(); } }
public void CheckBasicLogin() { List <dynamic> sites = ReadCSV.GetSites(TestContext.Properties["BasicLoginTestDataPath"].ToString()); int siteCount = sites.Count; IWebDriver driver = StartUp(); try { for (int j = 0; j < siteCount; j++) { try { BasicLogin.Execute(sites[j], driver); } catch (System.Exception ex) { throw ex; } finally { foreach (KeyValuePair <string, object> entry in sites[j]) { TestContext.WriteLine(entry.Key + ": " + entry.Value); } } } } catch (System.Exception ex) { throw ex; } finally { driver.Close(); driver.Dispose(); } }