sagesmoke 发表于 2014-7-14 15:04:05

将SeleniumIDE转化成JAVA脚本,在RC环境下跑 报错

有高手能帮忙看看是什么问题嘛?? 本人是新手,刚学这个。谢谢了
java.lang.RuntimeException: Could not start Selenium session: Failed to start new browser session: Error while launching browser
        at com.thoughtworks.selenium.DefaultSelenium.start(DefaultSelenium.java:89)
        at com.example.tests.test.setUp(test.java:16)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        at java.lang.reflect.Method.invoke(Unknown Source)
        at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47)
        at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
        at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44)
        at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:24)
        at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
        at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:271)
        at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70)
        at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50)
        at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238)
        at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63)
        at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236)
        at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53)
        at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229)
        at org.junit.runners.ParentRunner.run(ParentRunner.java:309)
        at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:50)
        at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
        at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
        at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
        at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
        at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
Caused by: com.thoughtworks.selenium.SeleniumException: Failed to start new browser session: Error while launching browser
        at com.thoughtworks.selenium.HttpCommandProcessor.throwAssertionFailureExceptionOrError(HttpCommandProcessor.java:97)
        at com.thoughtworks.selenium.HttpCommandProcessor.doCommand(HttpCommandProcessor.java:91)
        at com.thoughtworks.selenium.HttpCommandProcessor.getString(HttpCommandProcessor.java:262)
        at com.thoughtworks.selenium.HttpCommandProcessor.start(HttpCommandProcessor.java:223)
        at com.thoughtworks.selenium.DefaultSelenium.start(DefaultSelenium.java:81)
        ... 25 more

小暖ljj 发表于 2014-7-22 15:33:30

这个不是没运行selenium server服务的意思么,你可以运行下试试

cleanzhj 发表于 2014-10-10 15:47:11

你有运行java -jar selenium-server-standalone-2.39.0.jar 吗?

panzg 发表于 2014-10-10 17:13:08

把你代码贴上看看
页: [1]
查看完整版本: 将SeleniumIDE转化成JAVA脚本,在RC环境下跑 报错