public QuestionPage TypeSearchTextAndSelect(string pathway) { SearchTxtBox.Clear(); SearchTxtBox.SendKeys(pathway); this.ClickGoButton(); new WebDriverWait(_driver, TimeSpan.FromSeconds(5)).Until(ExpectedConditions.ElementIsVisible(By.XPath("//div[@class='results-list']/ul/li"))); _driver.FindElement(By.XPath("//div[@class='results-list']/ul/li/a[@data-title='" + pathway + "']")).Click(); return(new QuestionPage(_driver)); }
public QuestionPage TypeSearchTextAndSelect(string pathway) { SearchTxtBox.Clear(); SearchTxtBox.SendKeys(pathway); this.ClickNextButton(); new WebDriverWait(Driver, TimeSpan.FromSeconds(5)).Until(ExpectedConditions.ElementIsVisible(By.XPath("//ul[contains(@class, 'link-list') and contains(@class, 'link-list--results')]/li"))); Driver.FindElement(By.XPath("//ul[contains(@class, 'link-list') and contains(@class, 'link-list--results')]/li/a[@data-title='" + pathway + "']")).Click(); return(new QuestionPage(Driver)); }
public void SearchByTerm(string term) { SearchTxtBox.Clear(); SearchTxtBox.SendKeys(term); ClickNextButton(); }