Package uk.co.evoco.pageobjects
Class BasePageObject
java.lang.Object
uk.co.evoco.pageobjects.BasePageObject
public abstract class BasePageObject
extends java.lang.Object
This class is a base that all page objects can inherit from. It ensures that we have
a WebDriver object at the very least, and also takes care of initiating all of the annotated (@FindBy)
WebElements that are declared in page objects as fields.
The constructor of this class is called in every page objects constructor that inherits from this class.
-
Field Summary
-
Constructor Summary
Constructors Constructor Description BasePageObject(org.openqa.selenium.WebDriver webDriver)Initiates page elements that are declared as fields annotated @FindBy and makes the WebDriver instance available to child classes. -
Method Summary
-
Field Details
-
Constructor Details
-
BasePageObject
public BasePageObject(org.openqa.selenium.WebDriver webDriver)Initiates page elements that are declared as fields annotated @FindBy and makes the WebDriver instance available to child classes.- Parameters:
webDriver- active WebDriver instance
-