mil.dod.th.ose.gui.integration/src/mil/dod/th/ose/gui/integration/helpers/WebDriverFactory.java
private static WebDriver createWebDriver()
    {
        String desiredBrowser = System.getProperty(BROWSER_TYPE_PROP_NAME);
        if (desiredBrowser == null)
        {
            // use Firefox by default
            return createFirefoxDriverWithProfile();
        }
        else if (desiredBrowser.equals(FIREFOX_BROWSER))
        {
            return createFirefoxDriverWithProfile();
        }
        else if (desiredBrowser.equals(IE_BROWSER))
        {
            //IEDriverServer.exe needed for selenium tests to be ran if firefox is not the target. Must set the path 
            //where the exe is located as an environment variable.
            final File driverServer = new File(ResourceLocatorUtil.getWorkspacePath(), 
                    "deps/selenium-2.42.2/IEDriverServer.exe");
            System.setProperty("webdriver.ie.driver", driverServer.getAbsolutePath());
            return new InternetExplorerDriver();
        }
        else
        {
            throw new IllegalArgumentException(BROWSER_TYPE_PROP_NAME + " is not set to a valid browser name");
        }
    }
/**
     * Create a web driver based on the system property {@link #BROWSER_TYPE_PROP_NAME}.
     * 
     * @return
     *      Create the web driver for the desired browser
     */
Create a web driver based on the system property  #BROWSER_TYPE_PROP_NAME.

@return
Create the web driver for the desired browser
Create a web driver based on the system property #BROWSER_TYPE_PROP_NAME . @return Create the web driver for the desired browser
private static WebDriver createWebDriver()
    {
        String desiredBrowser = System.getProperty(BROWSER_TYPE_PROP_NAME);
        if (desiredBrowser == null)
        {
            return createFirefoxDriverWithProfile();
        }
        else if (desiredBrowser.equals(FIREFOX_BROWSER))
        {
            return createFirefoxDriverWithProfile();
        }
        else if (desiredBrowser.equals(IE_BROWSER))
        {
            final File driverServer = new File(ResourceLocatorUtil.getWorkspacePath(), 
                    "deps/selenium-2.42.2/IEDriverServer.exe");
            System.setProperty("webdriver.ie.driver", driverServer.getAbsolutePath());
            return new InternetExplorerDriver();
        }
        else
        {
            throw new IllegalArgumentException(BROWSER_TYPE_PROP_NAME + " is not set to a valid browser name");
        }
    }
private static WebDriver createWebDriver ( ) { String desiredBrowser = System . getProperty ( BROWSER_TYPE_PROP_NAME ) ; if ( desiredBrowser == null ) { return createFirefoxDriverWithProfile ( ) ; } else if ( desiredBrowser . equals ( FIREFOX_BROWSER ) ) { return createFirefoxDriverWithProfile ( ) ; } else if ( desiredBrowser . equals ( IE_BROWSER ) ) { final File driverServer = new File ( ResourceLocatorUtil . getWorkspacePath ( ) , "deps/selenium-2.42.2/IEDriverServer.exe" ) ; System . setProperty ( "webdriver.ie.driver" , driverServer . getAbsolutePath ( ) ) ; return new InternetExplorerDriver ( ) ; } else { throw new IllegalArgumentException ( BROWSER_TYPE_PROP_NAME + " is not set to a valid browser name" ) ; } }
Create a web driver based on the system property {@link #BROWSER_TYPE_PROP_NAME}.
Create a web driver based on the system property { @link #BROWSER_TYPE_PROP_NAME } .
// use Firefox by default //IEDriverServer.exe needed for selenium tests to be ran if firefox is not the target. Must set the path  //where the exe is located as an environment variable.