我给出了以下代码来使用 Firefox 启动应用程序
System.setProperty("webdriver.gecko.driver",
"C:/Work/Assessment/Automation/Test_2/src/main/resources/geckodriver.exe");
WebDriver driver = new FirefoxDriver();
driver.get("https://google.com");
我收到以下错误:
org.openqa.selenium.SessionNotCreatedException: Could not start a new session. Response code 500. Message: Expected browser binary location, but unable to find binary in default location, no 'moz:firefoxOptions.binary' capability provided, and no binary flag set on the command line
我想用firefox浏览器启动应用程序