public void UserProfileNotVisible() { // System.Threading.Thread.Sleep(5000); bool elementPresent = IsElementPresent(HelperFactory.SelectorByAttributeValue("data-qa", "signin-link")); Assert.IsTrue(elementPresent); }
public void UserLoggedOut() { Actions action = new Actions(driver); var element = driver.FindElement(HelperFactory.SelectorByAttributeValue("data-qa", "popupwindow-icon-userprofile")); action.MoveToElement(element).Perform(); ClickTheButtonByAttributeValue(String.Empty, "data-qa", "popupwindow-link-logout"); }
public void EnterTextIntoTextField(string text, string textFieldName, string atribute, string atrributeValue) { var WebDriverExtensions = new WebDriverExtensions(driver); var textField = WebDriverExtensions.FindElement(HelperFactory.SelectorByAttributeValue(atribute, atrributeValue)); driver.Manage().Timeouts().ImplicitWait = TimeSpan.FromSeconds(10); textField.SendKeys(text); }
public void UserProfileVisible() { CheckIfElementContainsText("You don't have any websites yet. Click Get Started to create your first website.", "h5"); Actions action = new Actions(driver); var element = driver.FindElement(HelperFactory.SelectorByAttributeValue("data-qa", "popupwindow-icon-userprofile")); action.MoveToElement(element).Perform(); bool elementPresent = IsElementPresent(HelperFactory.SelectorByAttributeValue("class", "user-name")); Assert.IsTrue(elementPresent); }
public void ClickTheButtonByAttributeValue(string buttonName, string atribute, string atrributeValue) { var button = driver.FindElement(HelperFactory.SelectorByAttributeValue(atribute, atrributeValue)); button.Click(); }