Driver executable must be set by the webdriver.ie.driver system property

后端 未结 5 1204
天命终不由人
天命终不由人 2020-11-28 05:09

I am using Selenium for automating the tests. My application exclusively uses IE, it will not work on other Browsers.

Code:

import org.openqa.seleniu         


        
5条回答
  •  -上瘾入骨i
    2020-11-28 05:59

    For spring :

    File inputFile = new ClassPathResource("\\chrome\\chromedriver.exe").getFile();
    System.setProperty("webdriver.chrome.driver",inputFile.getCanonicalPath());
    

提交回复
热议问题