Skip to content

Instantly share code, notes, and snippets.

@framiere
Created October 1, 2013 12:17
Show Gist options
  • Save framiere/6777584 to your computer and use it in GitHub Desktop.
Save framiere/6777584 to your computer and use it in GitHub Desktop.
public class LoginPage {
@FindBy(id = "j_username")
public WebElement user;
@FindBy(id = "j_password")
public WebElement password;
@FindBy(id = "login")
public WebElement loginButton;
public void login(String userValue, String passwordValue) {
user.clear();
user.sendKeys(userValue);
password.clear();
password.sendKeys(passwordValue);
loginButton.click();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment