BaseAppPage
open class BaseAppPage : BaseAppPageProtocol
Base implementation of the BaseAppPageProtocol
. All page objects can inherit from this class.
Example:
class MainPage: BaseAppPage {
var tableView: XCUIElement {
return view.tables[Locators.tableView]
}
}
private extension MainPage {
enum Locators: String, Locator {
case tableView
}
}
-
The container view on which all elements will be placed.
Note
view
can be an instance ofXCUIApplication
class.Declaration
Swift
open var view: XCUIElement
-
Initialize page object with container view.
Note
This view can be an instance of
XCUIApplication
class.Declaration
Swift
public init(in view: XCUIElement)
Parameters
view
Container view which contains all its page object elements.