public class WebDriverUtil extends Object
WebDriverLegacyITBase| Modifier and Type | Field and Description | 
|---|---|
| static int | DEFAULT_IMPLICIT_WAIT_TIMETODO apparent dup WebDriverITBase.DEFAULT_WAIT_SEC
 TODO parametrize for JVM Arg
 30 Seconds | 
| static boolean | JGROWL_ERROR_FAILUREfalse
 TODO upgrade to config via JVM param. | 
| static boolean | jGrowlEnabled | 
| static String | JS_HIGHLIGHT_BACKGROUNDgreen | 
| static String | JS_HIGHLIGHT_BOARDERgreen | 
| static String | JS_HIGHLIGHT_INPUT_PROPERTY-Dremote.driver.highlight.input= | 
| static int | JS_HIGHLIGHT_MS400 milliseconds | 
| static String | JS_HIGHLIGHT_MS_PROPERTY-Dremote.driver.highlight.ms= | 
| static String | JS_HIGHLIGHT_PROPERTY-Dremote.driver.highlight=true to enable highlighting of elements as selenium runs | 
| static boolean | jsHighlightEnabled | 
| static String | PROXY_HOST_PROPERTYlocal proxy used for running tests thru jmeter. | 
| static String | REMOTE_JGROWL_ENABLEDSet -Dremote.jgrowl.enabled= | 
| static String | REMOTE_LOGIN_UIFSet -Dremote.login.uif=KNS to use old login screen. | 
| static String | REMOTE_PUBLIC_CHROMESet -Dremote.public.chrome= or WEBDRIVER_CHROME_DRIVER | 
| static int | SETUP_URL_LOAD_WAIT_SECONDSTime to wait for the URL used in setup to load. | 
| static int | SHORT_IMPLICIT_WAIT_TIMETODO introduce SHORT_IMPLICIT_WAIT_TIME with param in WebDriverITBase
 TODO parametrize for JVM Arg
 1 Second | 
| static String | WEBDRIVER_CHROME_DRIVERSelenium's webdriver.chrome.driver parameter, you can set -Dwebdriver.chrome.driver= or Rice's REMOTE_PUBLIC_CHROME | 
| Constructor and Description | 
|---|
| WebDriverUtil() | 
| Modifier and Type | Method and Description | 
|---|---|
| static void | checkForIncidentReport(org.openqa.selenium.WebDriver driver,
                                            String locator,
                                            Failable failable,
                                            String message) | 
| static org.openqa.selenium.chrome.ChromeDriverService | chromeDriverCreateCheck() | 
| static String | deLinespace(String contents) | 
| static String | determineUser(String testParam) | 
| static void | failOnMatchedJira(String contents,
                                  Failable failable) | 
| static org.openqa.selenium.WebDriver | getWebDriver()remote.public.driver set to chrome or firefox (null assumes firefox)
 if remote.public.hub is set a RemoteWebDriver is created (Selenium Grid)
 if proxy.host is set, the web driver is setup to use a proxy | 
| static void | highlightElement(org.openqa.selenium.WebDriver webDriver,
                                org.openqa.selenium.WebElement webElement) | 
| static boolean | isKradLogin()Use the KRAD Login Screen or the old KNS Login Screen | 
| static void | jGrowl(org.openqa.selenium.WebDriver driver,
            String jGrowlHeader,
            boolean sticky,
            String message) | 
| static void | jGrowl(org.openqa.selenium.WebDriver driver,
            String jGrowlHeader,
            boolean sticky,
            String message,
            Throwable t) | 
| static void | jGrowlException(Throwable t) | 
| static void | kradLogin(org.openqa.selenium.WebDriver driver,
                  String userName,
                  Failable failable)Logs in using the KRAD Login Page
 If the JVM arg remote.autologin is set, auto login as admin will not be done. | 
| static void | login(org.openqa.selenium.WebDriver driver,
          String userName,
          Failable failable)Logs into the Rice portal using the KNS Style Login Page. | 
| static void | loginKradOrKns(org.openqa.selenium.WebDriver driver,
                            String user,
                            Failable failable) | 
| protected static void | selectFrameSafe(org.openqa.selenium.WebDriver driver,
                              String locator) | 
| static org.openqa.selenium.WebDriver | setUp(String username,
          String url)Setup the WebDriver test, login, and load the given web page | 
| static org.openqa.selenium.WebDriver | setUp(String username,
          String url,
          String className,
          String testName)Setup the WebDriver test, login, and load the given web page | 
| static void | tearDown(boolean passed,
                String sessionId,
                String testParam,
                String userParam) | 
| static org.openqa.selenium.WebElement | waitFor(org.openqa.selenium.WebDriver driver,
              int waitSeconds,
              org.openqa.selenium.By by,
              String message)Wait for the given amount of seconds, for the given by, using the given driver. | 
| static void | waitFors(org.openqa.selenium.WebDriver driver,
                int waitSeconds,
                org.openqa.selenium.By by,
                String message)Wait for the given amount of seconds, for the given by, using the given driver. | 
public static boolean jGrowlEnabled
public static boolean jsHighlightEnabled
public static int DEFAULT_IMPLICIT_WAIT_TIME
public static final boolean JGROWL_ERROR_FAILURE
public static final String JS_HIGHLIGHT_BACKGROUND
public static final String JS_HIGHLIGHT_BOARDER
public static final int JS_HIGHLIGHT_MS
public static final String JS_HIGHLIGHT_MS_PROPERTY
public static final String JS_HIGHLIGHT_PROPERTY
public static final String JS_HIGHLIGHT_INPUT_PROPERTY
public static int SHORT_IMPLICIT_WAIT_TIME
public static final String WEBDRIVER_CHROME_DRIVER
public static final String REMOTE_JGROWL_ENABLED
public static final String REMOTE_LOGIN_UIF
public static final String REMOTE_PUBLIC_CHROME
public static final int SETUP_URL_LOAD_WAIT_SECONDS
public static final String PROXY_HOST_PROPERTY
public WebDriverUtil()
public static org.openqa.selenium.WebDriver setUp(String username, String url) throws Exception
username - url - Exceptionpublic static org.openqa.selenium.WebDriver setUp(String username, String url, String className, String testName) throws Exception
username - url - className - testName - Exceptionpublic static void tearDown(boolean passed, String sessionId, String testParam, String userParam) throws Exception
passed - sessionId - testParam - userParam - Exceptionpublic static String determineUser(String testParam)
testParam - public static void checkForIncidentReport(org.openqa.selenium.WebDriver driver, String locator, Failable failable, String message)
driver - locator - message - public static org.openqa.selenium.chrome.ChromeDriverService chromeDriverCreateCheck()
public static void jGrowl(org.openqa.selenium.WebDriver driver, String jGrowlHeader, boolean sticky, String message, Throwable t)
public static void jGrowl(org.openqa.selenium.WebDriver driver, String jGrowlHeader, boolean sticky, String message)
public static void jGrowlException(Throwable t)
public static void highlightElement(org.openqa.selenium.WebDriver webDriver, org.openqa.selenium.WebElement webElement)
public static org.openqa.selenium.WebDriver getWebDriver()
public static void kradLogin(org.openqa.selenium.WebDriver driver, String userName, Failable failable) throws InterruptedException
driver - userName - failable - InterruptedExceptionpublic static void login(org.openqa.selenium.WebDriver driver, String userName, Failable failable) throws InterruptedException
driver - userName - failable - InterruptedExceptionpublic static void loginKradOrKns(org.openqa.selenium.WebDriver driver, String user, Failable failable) throws InterruptedException
InterruptedExceptionpublic static boolean isKradLogin()
protected static void selectFrameSafe(org.openqa.selenium.WebDriver driver, String locator)
public static org.openqa.selenium.WebElement waitFor(org.openqa.selenium.WebDriver driver, int waitSeconds, org.openqa.selenium.By by, String message) throws InterruptedException
driver - WebDriverwaitSeconds - intby - Bymessage - StringInterruptedExceptionpublic static void waitFors(org.openqa.selenium.WebDriver driver, int waitSeconds, org.openqa.selenium.By by, String message) throws InterruptedException
driver - WebDriverwaitSeconds - intby - Bymessage - StringInterruptedExceptionpublic static void failOnMatchedJira(String contents, Failable failable)
public static String deLinespace(String contents)
Copyright © 2005-2015 The Kuali Foundation. All Rights Reserved.