Skip to content

Instantly share code, notes, and snippets.

@martinschneider
Last active May 22, 2019 02:09
Show Gist options
  • Save martinschneider/cca688fd033aa3457f2f0569d81e455f to your computer and use it in GitHub Desktop.
Save martinschneider/cca688fd033aa3457f2f0569d81e455f to your computer and use it in GitHub Desktop.
Welcome page object
public class WelcomePage {
private WebDriver driver;
private By welcomePageLoginButton =
MobileBy.id("com.thecarousell.Carousell:id/welcome_page_login_button");
public WelcomePage(WebDriver driver) {
this.driver = driver;
}
public LoginPage goToLogin() {
WebDriverWait wait = new WebDriverWait(driver, 10);
wait.until(presenceOfElementLocated(welcomePageLoginButton)).click();
return new LoginPage(driver);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment