So, I was just creating a simple selenium/JBehave code when a question appeared. I'll
I'll first post the code simplified and then explain what is my question later.
@Component public class PageObjectSteps { private PageObject pageObject; @When("User wants to click on webElement1") public void accountToDeposit () { pageObject.waitPageLoad(); //Calling here just as an example pageObject.clickWebElement1(); } @When("User wants to type on webElement2 '$strType'") public void ammountToDepositamountToDeposit(@Named("strType") String strType) { pageObject.sendKeysWebElement2(strType); } }