Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save TikhomirovSergey/c2e5abebfd343479e8e942d0ae331eed to your computer and use it in GitHub Desktop.
Save TikhomirovSergey/c2e5abebfd343479e8e942d0ae331eed to your computer and use it in GitHub Desktop.
public void tezzt() throws Exception {
SeleniumSteps selenium = getSubstituted(SeleniumSteps.class, params());
Button button = selenium.find(element(button("B1"))
.foundFrom(link("L1"))
.foundFrom(webElement(xpath(""))));
List<Link> links = selenium.find(elements(links())
.foundFrom(button)
.foundFrom(webElement(xpath(""))));
List<TextField> textFields =
selenium.click(on(element(button("submit", ofSeconds(50))).foundFrom(webElement(xpath(""))))
.andOn(element(link()))
.andOn(button))
.find(elements(textFields()));
selenium.perform(action("High-level complex step", seleniumSteps -> {
//everything below will be documented as sub steps
seleniumSteps.click(on(element(tab("Some tab")))
.andOn(element(button("Some button", ofSeconds(50)))
.foundFrom(webElement(xpath("some path")))));
}));
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment