我无法启动IE浏览器来运行用Java编写的selenium自动化测试.我正在使用Windows 7和IE 9.以下是我的代码:
请找到附件.
public class GoogleNews {
private WebDriver driver;
private String baseUrl;
private StringBuffer verificationErrors = new StringBuffer();
ArrayList al = new ArrayList();
@Before
public void setUp() throws Exception {
//driver = new FirefoxDriver();
driver =new InternetExplorerDriver();
baseUrl = "https://news.google.co.in/";
}
@Test
public void testApple() throws Exception {
driver.get(baseUrl);
}
}
Run Code Online (Sandbox Code Playgroud)