Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save imeredith/985c1ebe211bc05aefe38c32dc5fb12a to your computer and use it in GitHub Desktop.

Select an option

Save imeredith/985c1ebe211bc05aefe38c32dc5fb12a to your computer and use it in GitHub Desktop.
test.java
@Singleton
public class ClassicFreestyleCreationPage {
@Inject
WebDriver driver;
@Inject @BaseUrl
String base;
@Inject
ClassicJobApi jobApi;
@FindBy(id = "name")
WebElement nameInput;
@Inject
public ClassicFreestyleCreationPage(WebDriver driver) {
PageFactory.initElements(driver, this);
}
public void createJob(String jobName) throws UnirestException {
driver.get(base + "/view/All/newJob");
jobApi.deleteJob(jobName);
nameInput.sendKeys(jobName);
driver.
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment