Package core.support.objects
Class DriverObject
java.lang.Object
core.support.objects.DriverObject
public class DriverObject extends Object
- Author:
- CAEHMAT driverList driver testId isAvailable ... A 1 false B 2 false C 1 true
-
Field Summary
Fields Modifier and Type Field Description StringappbrowserType.BrowserTypebrowserTypeorg.openqa.selenium.remote.DesiredCapabilitiescapabilitiesMap<String,Object>configstatic Map<org.openqa.selenium.WebDriver,DriverObject>driverListdriverType.DriverTypedriverTypeStringdriverVersionStringinitialURLBooleanisAvailableLoginObjectloginDriverOptionoptionsList<String>testIdListList<org.openqa.selenium.WebDriver>webdriver -
Constructor Summary
Constructors Constructor Description DriverObject() -
Method Summary
Modifier and Type Method Description org.openqa.selenium.remote.DesiredCapabilitiesgetCapabilties()static DriverObjectgetCurrentDriverObject()static StringgetCurrentTestId()static org.openqa.selenium.WebDrivergetFirstAvailableDriver()keeps track of all the drivers and selects the first available driver used when single sign in is usedURLgetInitURL()DriverOptiongetOptions()static StringgetPreviousTestId()returns the previous test id of the test ran on the driverstatic voidinitializeDriverList(DriverObject driver, String testId)add driver to driver list with test infostatic booleanisDriverSet()static voidquitAllDrivers()static voidquitTestDrivers()quite all drivers associated with a teststatic voidquitWebDriver(org.openqa.selenium.WebDriver driver)quits webdriver if it's runningstatic voidsetDriverAvailabiltity(org.openqa.selenium.WebDriver driver, boolean isAvailable)static voidshutDownDriver(boolean isTestPass)DriverObjectwithAndroidDriver(String app, String device)DriverObjectwithApiDriver(String app)DriverObjectwithApp(String app)DriverObjectwithBrowserType(browserType.BrowserType browserType)DriverObjectwithCapabilities(org.openqa.selenium.remote.DesiredCapabilities capabilities)DriverObjectwithDriverOptions(DriverOption driverOption)DriverObjectwithDriverType(driverType.DriverType driverType)DriverObjectwithDriverVersion(String driverVersion)DriverObjectwithGenericDriver(String app)DriverObjectwithiOSDriver(String app, String device)DriverObjectwithIsAvailable(Boolean isAvailable)DriverObjectwithTestId(String testId)DriverObjectwithUrl(String initialURL)DriverObjectwithWebDriver(String URL)DriverObjectwithWebDriver(String App, String URL)DriverObjectwithWinDriver(String app)
-
Field Details
-
webdriver
-
isAvailable
-
testIdList
-
initialURL
-
app
-
driverType
-
browserType
-
driverVersion
-
login
-
config
-
capabilities
public org.openqa.selenium.remote.DesiredCapabilities capabilities -
options
-
driverList
-
-
Constructor Details
-
DriverObject
public DriverObject()
-
-
Method Details
-
getFirstAvailableDriver
public static org.openqa.selenium.WebDriver getFirstAvailableDriver()keeps track of all the drivers and selects the first available driver used when single sign in is used- Returns:
-
quitTestDrivers
public static void quitTestDrivers()quite all drivers associated with a test -
quitWebDriver
public static void quitWebDriver(org.openqa.selenium.WebDriver driver)quits webdriver if it's running -
shutDownDriver
public static void shutDownDriver(boolean isTestPass) -
quitAllDrivers
public static void quitAllDrivers() -
initializeDriverList
add driver to driver list with test info- Parameters:
driver-testId-
-
setDriverAvailabiltity
public static void setDriverAvailabiltity(org.openqa.selenium.WebDriver driver, boolean isAvailable) -
withTestId
-
getCurrentTestId
-
getPreviousTestId
returns the previous test id of the test ran on the driver- Returns:
-
withApp
-
withIsAvailable
-
withUrl
-
withBrowserType
-
withDriverVersion
-
withDriverType
-
withDriverOptions
-
withCapabilities
-
getCapabilties
public org.openqa.selenium.remote.DesiredCapabilities getCapabilties() -
getOptions
-
getCurrentDriverObject
-
isDriverSet
public static boolean isDriverSet() -
withWebDriver
-
withWebDriver
-
withiOSDriver
-
withAndroidDriver
-
withWinDriver
-
withApiDriver
-
withGenericDriver
-
getInitURL
-