I've converted an NUnit test project from .NET Framework to .NET Core. When I try to execute a Selenium test using Visual Studio, I am seeing this error:
OpenQA.Selenium.DriverServiceNotFoundException : The chromedriver.exe file does not exist in the current directory or in a directory on the PATH environment variable. The driver can be downloaded at http://chromedriver.storage.googleapis.com/index.html.
I've included the Selenium.WebDriver.ChromeDriver
Nuget Package and chromedriver.exe
appears in the output bin folder. Without having to set the ChromeDriver url as an environment variable, how do I get Visual Studio to find the file?
[Test]
public void Test()
{
var driver = new ChromeDriver();
driver.Url = "http://www.google.com";
}
new ChromeDriver('.')
which will look at the CWD where the program is executed from. – Swimburger