Reputation: 1
Exception in thread "main" java.lang.IllegalStateException: The path to the driver executable must be set by the webdriver.chrome.driver system property; for more information, see https://github.com/SeleniumHQ/selenium/wiki/ChromeDriver. The latest version can be downloaded from http://chromedriver.storage.googleapis.com/index.html
Upvotes: 0
Views: 2054
Reputation: 1323
When you are setting the properties, you can't use uppercase
System.setProperty("webdriver.chrome.driver", System.getProperty("user.dir") + "/chromedriver.exe");
WebDriver driver = new ChromeDriver();
user.dir will take you to the current working directory.
Let me know if it works for you.
Upvotes: 0
Reputation: 51
Write "webdriver.chrome.driver" instead of "webdriver.chrome.Driver"
Just lowercase instead of uppercase.
Upvotes: 0