public void PopulatePageAndSubmit() { FirstName.SendKeys("Miller"); LastName.SendKeys("John"); UserEmail.SendKeys("*****@*****.**"); Gender.Click(); MobileNumber.SendKeys("0751123456"); DateOfBirth.Click(); Month.Click(); Year.Click(); Day.Click(); Subjects.SendKeys("Test subjects"); Thread.Sleep(2000); Hobbies.Click(); ((IJavaScriptExecutor)_driver).ExecuteScript("arguments[0].scrollIntoView(true);", Picture); //Thread.Sleep(5000); //Picture.Click(); CurrentAddress.SendKeys("Str. 13 Dec"); Thread.Sleep(2000); StateDropDown.Click(); StateOption.Click(); CityDropDown.Click(); CityOption.Click(); Submit.Click(); }
public BillingOrderPage ClickStateOption(State state) { CustomTestContext.WriteLine($"Click state option - '{state}'"); StateOption = Driver.FindElement(By.XPath(STATE_OPTION.Replace("{code}", state.ToString()))); StateOption.Click(); return(this); }
protected StateBase(Account account, StateOption option) { if (account == null) { throw new ArgumentNullException("account"); } Account = account; Option = option; }
public virtual void ChangeState(StateOption option) { if ((option == StateOption.Offline) || (option == Option)) { throw new NotSupportedException(); } Account.State = new StateFactory().Create(Account, option); TraceChangeState(Account, StateOption.Online, option); }
public void FillForm(RegistrationUser user) { RadioButton.Click(); FirstName.SendKeys(user.FirstName); LastName.SendKeys(user.LastName); Email.Clear(); Email.SendKeys(user.Email); Password.SendKeys(user.Password); DaysOption.SelectByIndex(user.DateOfBirth.Day); MonthsOption.SelectByIndex(user.DateOfBirth.Month); YearsOption.SelectByValue(user.DateOfBirth.Year.ToString()); SignUpNewsletter.Click(); Address_FirstName.SendKeys(user.Address.FirstName); Address_LastName.SendKeys(user.Address.LastName); Address_Address1.SendKeys(user.Address.Address1); Address_City.SendKeys(user.Address.City); StateOption.SelectByText(user.Address.State); Address_ZipCode.SendKeys(user.Address.ZipCode.ToString()); CountryOption.SelectByText(user.Address.Country); Address_Info.SendKeys(user.Address.Info); Address_MobPhone.SendKeys(user.Address.MobPhone); RegisterButton.Click(); }
public IState Create(Account account, StateOption option) { if (account == null) { throw new ArgumentNullException("account"); } switch (option) { case StateOption.Online: return(new OnlineState(account)); case StateOption.AppearOffline: return(new AppearOfflineState(account)); case StateOption.Busy: return(new BusyState(account)); case StateOption.Offline: return(new OfflineState(account)); default: throw new NotSupportedException(); } }
public void FillForm(User user) { FirstName.SendKeys(user.FirstName); LastName.SendKeys(user.LastName); Password.SendKeys(user.Password); Days.Click(); DayOption.Click(); Months.Click(); MonthOption.Click(); Years.Click(); YearOption.Click(); Address.SendKeys(user.Address); City.SendKeys(user.City); State.Click(); StateOption.Click(); Zip.SendKeys(user.ZipCode); HomePhone.SendKeys(user.HomePhone); Mobile.SendKeys(user.MobilePhone); AddressAlias.Clear(); AddressAlias.SendKeys(user.AddressAlias); RegisterButton.Click(); }
public void ChangeState(StateOption option) { State.ChangeState(option); }
public override void ChangeState(StateOption option) { throw new NotSupportedException(); }
static void TraceChangeState(Account account, StateOption original, StateOption current) { TraceMessage(Resource.ChangeStateText, account.Name, original, current); }
public override void OnEnter(StateOption priorState) { endTime = Time.time + 5f; }