![Trending Articles on Technical and Non Technical topics](/images/trending_categories.jpeg)
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
How to run Selenium tests on Internet Explorer browser?
We can run Selenium tests on the Internet Explorer browser with the help of the Selenium IE driver. It is an independent server that works on the protocols of the webdriver and serves as a communication between the Internet Explorer browser and the Selenium code.
First, we have to download the IEDriverServer.exe file from the following link − https://www.selenium.dev/downloads/.
Then click on the download link (32 or 64 bit) based on our local operating system.
Once the download is completed, a zip file gets saved. It needs to be extracted and stored in a location. After extracting it, the executable file - IEDriverServer.exe file is to be kept at a desired location.
We have to configure the path of the IEDriverServer.exe file using the System.setProperty method along with creating an object of the InternetExplorerDriver class.
Syntax
System.setProperty("webdriver.ie.driver", "C:\Users\ghs6kor\Desktop\Java\IEDriverServer.exe"); WebDriver driver = new InternetExplorerDriver();
Example
import org.openqa.selenium.WebDriver; import org.openqa.selenium.ie.InternetExplorerDriver; public class IEBrwserLaunch{ public static void main(String[] args) { //configure path of IEDriverServer.exe path System.setProperty("webdriver.ie.driver", "C:\Users\ghs6kor\Desktop\Java\IEDriverServer.exe"); //object of InternetExplorerDriver WebDriver driver = new InternetExplorerDriver(); //URL launch driver.get("https://www.yahoo.com/"); } }