public void ClickOnEditLink() { if (EditLink.Displayed) { EditLink.Click(); } else { Exception e; } }
public void ClickOnEditLink() { if (EditLink.Displayed) { EditLink.Click(); } else { throw new Exception("Element is not found or not clickable"); } }
/// <summary> /// edit /// </summary> public void SelectEdit() { EditLink.Click(); }
/// <summary> /// click the edit link /// </summary> public void SelectEdit() { EditLink.Click(); //on passage type, returns /Assess/Items/EditPassage.aspx //on item type, returns /Assess/Items/EditTestItem.aspx }
public void FeeList_Submission_SPP() { AJAXCall.WaitForAjax(); Thread.Sleep(900); CommonUtils cookiesScreen = new CommonUtils(driver); cookiesScreen.RejectAll_Cookies(); Thread.Sleep(900); SignIn_Page.Click(); Excel_Suite userEmail = new Excel_Suite(Env.EXCEL_TEST_URL); userEmail.getCellData("SPP_TestData", true); UserEmail.SendKeys(Env.Email_Id); Password.SendKeys("Test@123"); WebDriverWait wait = new WebDriverWait(driver, System.TimeSpan.FromSeconds(800)); Thread.Sleep(800); SubmitButton.Click(); MyAccount_Toggle.Click(); AJAXCall.WaitForAjax(); FeesList_Link.Click(); AJAXCall.WaitForAjax(); Thread.Sleep(1000); EditLink.Click(); EditButton.Click(); createBox.Click(); Thread.Sleep(800); driver.SwitchTo().Frame(1); Eyp_name.SendKeys("TestAutomation"); Eyp_agerange.SendKeys("5-10"); SelectElement option = new SelectElement(Eyp_ecceavailable); option.SelectByText("Yes"); Eyp_fullpriceperweek_Text.SendKeys("100.00"); Thread.Sleep(800); Eyp_daysperweek.SendKeys("5"); Eyp_hoursperweek.SendKeys("40"); Effective_Date.SendKeys("01/11/2020"); InsertButton.Click(); AJAXCall.WaitForAjax(); driver.SwitchTo().DefaultContent(); }
public EditPage edit() { EditLink.Click(); return(new EditPage(_driver)); }
public void SearchThroughAccountName(IWebDriver driver) { SignIn_Page.Click(); UserEmail.SendKeys("*****@*****.**"); Password.SendKeys("Test@123"); WebDriverWait wait = new WebDriverWait(driver, TimeSpan.FromSeconds(800)); Thread.Sleep(800); SubmitButton.Click(); MyAccount_Toggle.Click(); BankAccount_Page.Click(); AJAXCall.WaitForAjax(); Thread.Sleep(1000); downArrow.Click(); wait = new WebDriverWait(driver, TimeSpan.FromSeconds(900)); Thread.Sleep(1000); EditLink.Click(); Actions action = new Actions(driver); action.KeyDown(Keys.Control).SendKeys(Keys.End).Perform(); NextButton.Click(); AJAXCall.WaitForAjax(); Thread.Sleep(2000); if (AJAXCall.IsElementPresent(By.PartialLinkText("Upload Document"))) { action.KeyDown(Keys.Control).SendKeys(Keys.End).Perform(); NextButton.Click(); } else { Thread.Sleep(1000); } AJAXCall.WaitForAjax(); Thread.Sleep(1000); Thread.Sleep(2000); wait = new WebDriverWait(driver, TimeSpan.FromSeconds(100)); if (AJAXCall.IsElementPresent(By.Id("eyp_validationcode"))) { Excel_Suite read_BankCode = new Excel_Suite(@"C:\Pobal_AutomationProject\Pobal_Test_Project\Automation_Suite\TestData_Repository\BankCode.xlsx"); read_BankCode.getCellData("Bank_Sheet", false); IWebElement value_Code = driver.FindElement(By.XPath("//*[@id='eyp_validationcode']")); value_Code.Click(); value_Code.Clear(); Thread.Sleep(2000); value_Code.SendKeys(Keys.Tab); value_Code.SendKeys(Env.Data_Retrieve); } NextButton.Click(); }