Skip to content
This is an example Selenium 2.25.0 script that runs in IE 10 on Windows 8 using maven
Java
Find file
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
src/test/java/testcases
.gitignore
README.md
execute.bat
pom.xml

README.md

Selenium 2.25.0 / Windows 8 / IE 10 / Maven - Example

This is just an example of how to create a simple selenium 2.x script that will run on Windows 8 in IE 10 via Maven.

Requirements

Tips

  • Use the Windows PowerShell, not the typical shell that 'cmd' launches
  • If you are running Windows 8 in a VM, or just don't like Eclipse, use Sublime Text - http://www.sublimetext.com

How to Run

  • In a Windows PowerShell run the following command in the selenium-ie10-example folder. (The directory with the pom.xml file)

      mvn clean integration-test
    
  • Or run the execute.bat file, which does the exact same thing.

Example Output

Maven spits out lots of stuff, especially the first time you run it. The TESTS section is what you want to pay attention to. That said, ignore all the errors that the driver dumps in there when it is starting up.

-------------------------------------------------------
 T E S T S
-------------------------------------------------------
Running testcases.SeleniumTest
The path to the driver executable must be set by the webdriver.ie.driver system property; for more information, see http
://code.google.com/p/selenium/wiki/InternetExplorerDriver. The latest version can be downloaded from http://code.google.
com/p/selenium/downloads/list
Aug 31, 2012 10:08:59 PM org.openqa.selenium.ie.InternetExplorerDriverServer initializeLib
WARNING: This method of starting the IE driver is deprecated and will be removed in selenium 2.26. Please download the I
EDriverServer.exe from http://code.google.com/p/selenium/downloads/list and ensure that it is in your PATH.
Aug 31, 2012 10:09:01 PM org.apache.http.impl.client.DefaultRequestDirector tryExecute
INFO: I/O exception (org.apache.http.NoHttpResponseException) caught when processing request: The target server failed t
o respond
Aug 31, 2012 10:09:01 PM org.apache.http.impl.client.DefaultRequestDirector tryExecute
INFO: Retrying request
page 0 load time: 4.119
page 1 load time: 3.477
page 2 load time: 3.799
  total page load time: 11.395
average page load time: 3.7983333333333333
     longest load time: 4.119
    shortest load time: 3.477
 empty cache load tiem: 4.119
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 15.629 sec

Results :

Tests run: 1, Failures: 0, Errors: 0, Skipped: 0

[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 20.035s
[INFO] Finished at: Fri Aug 31 22:09:14 PDT 2012
[INFO] Final Memory: 12M/31M
[INFO] ------------------------------------------------------------------------
Something went wrong with that request. Please try again.