How can I start InternetExplorerDriver using Selenium WebDriver

前端 未结 16 2692
半阙折子戏
半阙折子戏 2020-12-30 17:23

I downloaded the driver and I gave the exact path in my code but when I ran the code it shows me error

my code with java is as below:

System.out.prin         


        
16条回答
  •  猫巷女王i
    2020-12-30 17:36

    To run test cases in IE Browser make sure you have downloaded IE driver and you need to set the property as well.

    Below code will help you

    // This will set the driver
    System.setProperty("webdriver.ie.driver","driver path\\IEDriverServer.exe");
    
    // Initialise browser
    
    WebDriver driver=new InternetExplorerDriver();
    

    You can check IE Browser challenges with Selenium and complete code for more details

提交回复
热议问题