-2

我对这一切都很陌生,设置它有点不知所措。我正在使用 ant 使用 testng 套件运行一堆测试。

它到达了我收到此错误的地步:

[testng] Failed to invoke @Configuration method org.springframework.test.context.testng.AbstractTestNGSpringContextTests.springTestContextPrepareTestInstance:Error creating bean with name 'com.mystuffs.tests1.CreateTest1': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire method: public void com.mystuffs.web.BrowserTest1.setBrowser(com.mystuffs.web.browser.Browser); nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'browser' defined in class path resource [applicationcontext.xml]: Invocation of init method failed; nested exception is java.lang.RuntimeException: Could not start Selenium session: Failed to start new browser session: Error while launching browser

它看起来像是某种依赖问题,但我不确定如何继续。任何建议表示赞赏!

4

1 回答 1

0

无论您尝试什么:问题是您在启动应用程序时尝试实例化 Selenium 浏览器会话,但失败了:

java.lang.RuntimeException:无法启动 Selenium 会话:无法启动新的浏览器会话:启动浏览器时出错

所以你应该看看为什么 selenium 不能启动浏览器

于 2012-08-24T07:41:39.923 回答