public void TestUpdateInvalidToValidToInvalid() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.Value.Wait().EqualTo("bad"); page.Input.Click(); page.Input.TabOut(); page.Input.WaitError(); page.InputValidation.Label.WaitText("incorrect value"); page.Input.Click(); page.Input.SendKeys(Keys.End); page.Input.SendKeys(Keys.Backspace); page.Input.WaitNoError(); page.InputValidation.Label.WaitText("incorrect value"); page.Input.SendKeys("d"); page.Input.WaitNoError(); page.InputValidation.Label.WaitText("incorrect value"); page.Input.TabOut(); page.Input.WaitError(); page.InputValidation.Label.WaitText("incorrect value"); }
public void TestInvalidByDefault() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.Value.Wait().EqualTo("bad"); page.Input.WaitError(); page.InputValidation.Label.WaitText("incorrect value"); }
public void TestValidByDefault() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.WaitNoError(); page.ValidationState.WaitText("none"); page.InputValidation.Label.WaitAbsent(); }
public void TestDoNotValidateUntilSubmit() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.SetValue("bad"); page.Input.WaitNoError(); page.InputValidation.Label.WaitAbsent(); }
public void TestFocusWhenNothing() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.SubmitButton.Click(); page.ValidationState.WaitText("valid"); page.Input.WaitNotFocus(); }
public void TestValidByDefault() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.Value.Wait().EqualTo("bad"); page.Input.WaitNoError(); page.InputValidation.Label.WaitAbsent(); }
public void TestValidateOnLostfocus() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.SetValue("bad"); page.Input.WaitError(); page.ValidationState.WaitText("none"); page.InputValidation.Label.WaitText("incorrect value"); }
public void TestFocusWhenError() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.SetValue("bad"); page.SubmitButton.Click(); page.Input.WaitError(); page.Input.WaitFocus(); }
public void TestValidOnSubmit() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.SetValue("ok"); page.SubmitButton.Click(); page.Input.WaitNoError(); page.ValidationState.WaitText("valid"); page.InputValidation.Label.WaitAbsent(); }
public void TestResetValidationAfterEdit() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.SetValue("bad"); page.SubmitButton.Click(); page.Input.SetValue("bad"); page.Input.WaitNoError(); page.InputValidation.Label.WaitAbsent(); }
public void TestValidateOnSubmit() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.SetValue("bad"); page.SubmitButton.Click(); page.Input.WaitError(); page.ValidationState.WaitText("invalid"); page.InputValidation.Label.WaitText("incorrect value"); }
public void TestValidateImmediately() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.InputValue("bad"); page.Input.WaitNoError(); page.InputValidation.Label.WaitText("incorrect value"); page.Input.TabOut(); page.Input.WaitError(); page.InputValidation.Label.WaitText("incorrect value"); }
public void TestDoNotValidateUntilLostfocus() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.InputValue("bad"); page.Input.WaitNoError(); page.InputValidation.Label.WaitAbsent(); page.Input.TabOut(); page.Input.WaitError(); page.InputValidation.Label.WaitPresent(); }
public void TestUpdateInvalidToValid() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.Value.Wait().EqualTo("bad"); page.Input.InputValue("ok"); page.Input.WaitNoError(); page.InputValidation.Label.WaitText("incorrect value"); page.Input.TabOut(); page.Input.WaitNoError(); page.InputValidation.Label.WaitAbsent(); }
public void TestUpdateInvalidToValid() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.SetValue("bad"); page.Input.WaitError(); page.Input.InputValue("ok"); page.Input.WaitNoError(); page.InputValidation.Label.WaitAbsent(); page.Input.TabOut(); page.Input.WaitNoError(); page.InputValidation.Label.WaitAbsent(); }
public void TestUpdateInvalidToValid() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.SetValue("bad"); page.Input.Click(); page.Input.SendKeys(Keys.End); page.Input.SendKeys(Keys.Backspace); page.Input.WaitNoError(); page.InputValidation.Label.WaitAbsent(); page.Input.TabOut(); page.Input.WaitNoError(); page.InputValidation.Label.WaitAbsent(); }
public void TestFocusWhenWarning() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.ValidationLevel.ExecuteAction(x => { var tag = x.FindElement(By.CssSelector("button")); tag.Click(); tag.SendKeys(Keys.Down); tag.SendKeys(Keys.Down); tag.SendKeys(Keys.Enter); }, "SetValue('warning')"); page.Input.SetValue("bad"); page.SubmitButton.Click(); page.Input.WaitWarning(); page.Input.WaitFocus(); }
public void TestUpdateInvalidToInvalid() { var page = new SingleInputPage(GetWebDriver()).WaitReady(); page.Input.SetValue("bad"); page.SubmitButton.Click(); page.Input.WaitError(); page.Input.Click(); page.Input.SendKeys(Keys.End); page.Input.SendKeys("d"); page.Input.WaitNoError(); page.InputValidation.Label.WaitText("incorrect value"); page.Input.TabOut(); page.Input.WaitError(); page.InputValidation.Label.WaitText("incorrect value"); }