/* * public LoginPage(IWebDriver driver) * { * this.driver = driver; * PageFactory.InitElements(driver, this); * } */ public void LoginToApplication(string testName) { var userData = ExcelDataAccess.GetTestData(testName); // UserName.Clear(); // UserName.SendKeys(userData.Username); UserName.EnterText(userData.Username, "id_username"); // Password.Clear(); // Password.SendKeys(userData.Password); Password.EnterText(userData.Password, "password"); // Login.Submit(); // Logout.Click(); // LoginAgain.Click(); Login.ClickOnIt("submit"); Logout.ClickOnIt("LOG OUT"); LoginAgain.ClickOnIt("Log in again"); }