public RegistrationPage FillAndSubmitRegistrationForm(string login, string email, string name, string surname, string phone, string password, string confirmPassword) { LoginField.SendKeys(login); EmailField.SendKeys(email); NameField.SendKeys(name); SurnameField.SendKeys(surname); PhoneField.SendKeys(phone); PasswordField.SendKeys(password); RepeatPasswordField.SendKeys(confirmPassword); TestDataHelper.ClickRandomDate(BirthDateField); UnitField.Click(); EridCells = Factory.TryFindElements(By.XPath(RegistrationPageLocators.GridCellsLocator)); TestDataHelper.ClickRandomGridCell(EridCells); ConfirmationButton.Click(); return(new RegistrationPage()); }
public string FillLoginForm(string username, string password, string repeatPassword) { UsernameField.Clear(); UsernameField.SendKeys(username); PasswordField.Clear(); PasswordField.SendKeys(password); RepeatPasswordField.Clear(); RepeatPasswordField.SendKeys(repeatPassword); LoginButton.Click(); var appAlert = _driver.SwitchTo().Alert(); var tempstr = appAlert.Text; appAlert.Accept(); return(tempstr); }
public RegistrationPage aa(string birthDate, params string[] vs) { foreach (var item in vs) { LoginField.SendKeys(item); EmailField.SendKeys(item); NameField.SendKeys(item); SurnameField.SendKeys(item); PhoneField.SendKeys(item); PasswordField.SendKeys(item); RepeatPasswordField.SendKeys(item); } TestDataHelper.ClickRandomDate(BirthDateField); UnitField.Click(); EridCells = Factory.TryFindElements(By.XPath(RegistrationPageLocators.GridCellsLocator)); TestDataHelper.ClickRandomGridCell(EridCells); ConfirmationButton.Click(); return(new RegistrationPage()); }