So finally added support to execute tests on Internet Explorer browser also in my github project https://github.com/lalit-k/selenium-java-tests.
3 Simple steps to add Internet Explorer support in Selenium Webdriver project:
Tip : you can use the "System.getProperty("user.dir");" to get the current working directory and then append the path to IEDriverServer.exe
You can also view the complete code changes for your reference at https://github.com/lalit-k/selenium-java-tests/commit/d1dc4cd3f878d64a4119fc0d6297df026a07cf5a
3 Simple steps to add Internet Explorer support in Selenium Webdriver project:
- Download the IEDriverServer.exe , you can download the latest version from http://selenium-release.storage.googleapis.com/index.html for your target operating system.[download url may change, you can google latest if it changes]
- Extract the IEDriverServer.exe from the downloaded zip, and place in your project resources folder.
IEDriverServer.exe - Now, go to the Driver script where you are initializing the IEDriverServer and add the below code line to initialize the IEDriverServer.
System.setProperty("webdriver.ie.driver", <full system path of the IEDriverServer.exe. Example: c:\tests\resources\IEDriverServer.exe>);
WebDriver driver = new InternetExplorerDriver();
Tip : you can use the "System.getProperty("user.dir");" to get the current working directory and then append the path to IEDriverServer.exe
System.getProperty("user.dir") |
1 comment:
Great Post,really it was very helpful for us.
Thanks a lot for sharing!
I found this blog to be very useful!!
Software testing training in Bangalore
Post a Comment