公共类loadChrome {
@Test
Public void openBrowser()
{
//Setting up the driver path on the piece of code below
System.setProperty("webdriver.chrome.driver", "path goes here");
//In this line, I am defining the web driver instance
WebDriver driver = new FirefoxDriver();
driver.get("https://www.google.com/");//Telling the driver to open Google website
driver.close(); //Closing the driver
}
}
我尝试调试代码以查看失败的地方。我注意到它甚至不能简单地打开Web驱动程序实例。
我希望输出为:测试运行:1,故障:0,跳过:0,但实际输出是测试运行:0,故障:0,跳过:0