LiTiang / js-test-driver

Automatically exported from code.google.com/p/js-test-driver
0 stars 0 forks source link

Floating BrowserPanicException/FailureException #247

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Create some simple tests
2. java -jar JsTestDriver-1.3.2.jar --browser /usr/bin/firefox --tests-all 
--verbose

What is the expected output? What do you see instead?
Sometimes everything's ok, but sometimes I get 
BrowserPanicException/FailureException (see attached files).

What version of the product are you using? On what operating system?
js-test-driver 1.3.2, java 1.6.0_24, Linux 2.6.38-8-generic-pae i686 i386, 
Firefox 4 & 5

Please provide any additional information below.
It occurs on the same tests (without any modifications). I use Ant to run 
tests, so here's my target:
<target name="test" depends="build">

    <property name="browsers" value="/usr/bin/firefox"/>

    <java jar="tools/js-test-driver/JsTestDriver-1.3.2.jar" fork="true">
        <arg line="--browser ${browsers}"/>
        <arg line="--tests all"/>
        <arg line="--verbose"/>
        <arg line="--runnerMode DEBUG"/>
    </java>

</target>

Original issue reported on code.google.com by andrew.p...@gmail.com on 24 Jun 2011 at 7:29

Attachments:

GoogleCodeExporter commented 9 years ago
The same problem. Tests are sometimes failed on Chrome.
It looks like tests are executed and it fails somewhere in the middle. Happens 
occasionaly. 

StackTrace:
java
......................................................................
......................................................................
......................................................................
................Failures during test run.
Caused by:
com.google.jstestdriver.FailureException: Browser is not available
 DEAD:{"id":1316596765489,"name":"Chrome","version":"14.0.835.163","os":"Windows","uploadSize":50,"serverReceivedHeartbeat":false} 
 for
 {data={"command":"runTests","parameters":["[\"all\"]","false",""]}, id=1316596765489}
    at com.google.jstestdriver.CommandTask.checkBrowser(CommandTask.java:80)
    at com.google.jstestdriver.CommandTask.run(CommandTask.java:99)
    at com.google.jstestdriver.JsTestDriverClientImpl.sendCommand(JsTestDriverClientImpl.java:85)
    at com.google.jstestdriver.JsTestDriverClientImpl.runTests(JsTestDriverClientImpl.java:118)
    at com.google.jstestdriver.JsTestDriverClientImpl.runAllTests(JsTestDriverClientImpl.java:99)
    at com.go......................................................
......................................................................
......................................................................
........................................................ogle.jstestdriver.RunTes
tsAction.run(RunTestsAction.java:61)
    at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:68)
    at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:37)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
    at java.util.concurrent.FutureTask.run(FutureTask.java:138)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
    at java.util.concurrent.FutureTask.run(FutureTask.java:138)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:98)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:206)
    at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPool..............
......................................................................
................................Executor.java:886)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
    at java.lang.Thread.run(Thread.java:662)

    at com.google.jstestdriver.browser.BrowserActionExecutorAction.run(BrowserActionExecutorAction.java:142)
    at com.google.jstestdriver.ActionRunner.runActions(ActionRunner.java:64)
    at com.google.jstestdriver.JsTestDriver.main(JsTestDriver.java:86)
Caused by:
com.google.jstestdriver.FailureException: Browser is not available
 DEAD:{"id":1316596765489,"name":"Chrome","version":"14.0.835.163","os":"Windows","uploadSize":50,"serverReceivedHeartbeat":false} 
 for
 {data={"command":"runTests","parameters":["[\"all\"]","false",""]}, id=1316596765489}
Unexpected Runner Condition: Failures during test run.

Original comment by volodymy...@gmail.com on 21 Sep 2011 at 9:24

GoogleCodeExporter commented 9 years ago
I'm seeing a similar issue, if I run it with  --runnerMode DEBUG it shows me 
that the browser is refusing to exit. Attaching the output from running an 
extremely simple test. Experience with 1.3.2, 1.3.3b, and 1.3.3c

Original comment by nat...@sociablelabs.com on 20 Oct 2011 at 5:59

Attachments:

GoogleCodeExporter commented 9 years ago
This bug is reproduced on IE9 and Firefox, not only on chrome.
I am executing the test on the latest jstestdriver jar (JsTestDriver-1.3.5.jar):

java -jar JsTestDriver-1.3.5.jar --server <server-url> --config <jstd-config> 
--testOutput <test-output> --verbose --runnerMode DEBUG --tests all.

since this bug reproduces on all browsers I'll appreciate if you increase its 
priority.

Attached log:

Dec 31, 2012 12:05:48 PM com.google.jstestdriver.Main main
FINE: Error {}
Failures during test run.
Caused by:
com.google.jstestdriver.browser.BrowserPanicException: Browser Microsoft 
Internet Explorer 9.0 Windows
During Page reloaded unexpectedly during or after null triggered by beforeunload
    at com.google.jstestdriver.CommandTask.run(CommandTask.java:136)
    at com.google.jstestdriver.JsTestDriverClientImpl.sendCommand(JsTestDriverClientImpl.java:103)
    at com.google.jstestdriver.JsTestDriverClientImpl.runTests(JsTestDriverClientImpl.java:141)
    at com.google.jstestdriver.JsTestDriverClientImpl.runAllTests(JsTestDriverClientImpl.java:120)
    at com.google.jstestdriver.RunTestsAction.run(RunTestsAction.java:69)
    at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:70)
    at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:37)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
    at java.util.concurrent.FutureTask.run(FutureTask.java:166)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
    at java.util.concurrent.FutureTask.run(FutureTask.java:166)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:178)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:292)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
    at java.lang.Thread.run(Thread.java:722)
com.google.jstestdriver.browser.BrowserPanicException: Browser Chrome 
23.0.1271.97 Windows
During Page reloaded unexpectedly during or after null triggered by beforeunload
    at com.google.jstestdriver.CommandTask.run(CommandTask.java:136)
    at com.google.jstestdriver.JsTestDriverClientImpl.sendCommand(JsTestDriverClientImpl.java:103)
    at com.google.jstestdriver.JsTestDriverClientImpl.runTests(JsTestDriverClientImpl.java:141)
    at com.google.jstestdriver.JsTestDriverClientImpl.runAllTests(JsTestDriverClientImpl.java:120)
    at com.google.jstestdriver.RunTestsAction.run(RunTestsAction.java:69)
    at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:70)
    at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:37)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
    at java.util.concurrent.FutureTask.run(FutureTask.java:166)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
    at java.util.concurrent.FutureTask.run(FutureTask.java:166)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:178)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:292)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
    at java.lang.Thread.run(Thread.java:722)
    at com.google.jstestdriver.browser.BrowserActionExecutorAction.run(BrowserActionExecutorAction.java:154)
    at com.google.jstestdriver.ActionRunner.runActions(ActionRunner.java:81)
    at com.google.jstestdriver.embedded.JsTestDriverImpl.runConfigurationWithFlags(JsTestDriverImpl.java:342)
    at com.google.jstestdriver.embedded.JsTestDriverImpl.runConfiguration(JsTestDriverImpl.java:233)
    at com.google.jstestdriver.Main.main(Main.java:70)
Caused by:com.google.jstestdriver.browser.BrowserPanicException: Browser 
Microsoft Internet Explorer 9.0 Windows
During Page reloaded unexpectedly during or after null triggered by beforeunload
com.google.jstestdriver.browser.BrowserPanicException: Browser Microsoft 
Internet Explorer 9.0 Windows
During Page reloaded unexpectedly during or after null triggered by beforeunload
    at com.google.jstestdriver.CommandTask.run(CommandTask.java:136)
    at com.google.jstestdriver.JsTestDriverClientImpl.sendCommand(JsTestDriverClientImpl.java:103)
    at com.google.jstestdriver.JsTestDriverClientImpl.runTests(JsTestDriverClientImpl.java:141)
    at com.google.jstestdriver.JsTestDriverClientImpl.runAllTests(JsTestDriverClientImpl.java:120)
    at com.google.jstestdriver.RunTestsAction.run(RunTestsAction.java:69)
    at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:70)
    at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:37)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
    at java.util.concurrent.FutureTask.run(FutureTask.java:166)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
    at java.util.concurrent.FutureTask.run(FutureTask.java:166)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:178)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:292)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
    at java.lang.Thread.run(Thread.java:722)
Caused by:com.google.jstestdriver.browser.BrowserPanicException: Browser Chrome 
23.0.1271.97 Windows
During Page reloaded unexpectedly during or after null triggered by beforeunload
com.google.jstestdriver.browser.BrowserPanicException: Browser Chrome 
23.0.1271.97 Windows
During Page reloaded unexpectedly during or after null triggered by beforeunload
    at com.google.jstestdriver.CommandTask.run(CommandTask.java:136)
    at com.google.jstestdriver.JsTestDriverClientImpl.sendCommand(JsTestDriverClientImpl.java:103)
    at com.google.jstestdriver.JsTestDriverClientImpl.runTests(JsTestDriverClientImpl.java:141)
    at com.google.jstestdriver.JsTestDriverClientImpl.runAllTests(JsTestDriverClientImpl.java:120)
    at com.google.jstestdriver.RunTestsAction.run(RunTestsAction.java:69)
    at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:70)
    at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:37)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
    at java.util.concurrent.FutureTask.run(FutureTask.java:166)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
    at java.util.concurrent.FutureTask.run(FutureTask.java:166)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:178)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:292)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
    at java.lang.Thread.run(Thread.java:722)
Failures during test run.
Caused by:
com.google.jstestdriver.browser.BrowserPanicException: Browser Microsoft 
Internet Explorer 9.0 Windows
During Page reloaded unexpectedly during or after null triggered by beforeunload
    at com.google.jstestdriver.CommandTask.run(CommandTask.java:136)
    at com.google.jstestdriver.JsTestDriverClientImpl.sendCommand(JsTestDriverClientImpl.java:103)
    at com.google.jstestdriver.JsTestDriverClientImpl.runTests(JsTestDriverClientImpl.java:141)
    at com.google.jstestdriver.JsTestDriverClientImpl.runAllTests(JsTestDriverClientImpl.java:120)
    at com.google.jstestdriver.RunTestsAction.run(RunTestsAction.java:69)
    at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:70)
    at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:37)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
    at java.util.concurrent.FutureTask.run(FutureTask.java:166)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
    at java.util.concurrent.FutureTask.run(FutureTask.java:166)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:178)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:292)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
    at java.lang.Thread.run(Thread.java:722)
com.google.jstestdriver.browser.BrowserPanicException: Browser Chrome 
23.0.1271.97 Windows
During Page reloaded unexpectedly during or after null triggered by beforeunload
    at com.google.jstestdriver.CommandTask.run(CommandTask.java:136)
    at com.google.jstestdriver.JsTestDriverClientImpl.sendCommand(JsTestDriverClientImpl.java:103)
    at com.google.jstestdriver.JsTestDriverClientImpl.runTests(JsTestDriverClientImpl.java:141)
    at com.google.jstestdriver.JsTestDriverClientImpl.runAllTests(JsTestDriverClientImpl.java:120)
    at com.google.jstestdriver.RunTestsAction.run(RunTestsAction.java:69)
    at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:70)
    at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:37)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
    at java.util.concurrent.FutureTask.run(FutureTask.java:166)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
    at java.util.concurrent.FutureTask.run(FutureTask.java:166)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:178)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:292)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
    at java.lang.Thread.run(Thread.java:722)
    at com.google.jstestdriver.browser.BrowserActionExecutorAction.run(BrowserActionExecutorAction.java:154)
    at com.google.jstestdriver.ActionRunner.runActions(ActionRunner.java:81)
    at com.google.jstestdriver.embedded.JsTestDriverImpl.runConfigurationWithFlags(JsTestDriverImpl.java:342)
    at com.google.jstestdriver.embedded.JsTestDriverImpl.runConfiguration(JsTestDriverImpl.java:233)
    at com.google.jstestdriver.Main.main(Main.java:70)
Caused by:
com.google.jstestdriver.browser.BrowserPanicException: Browser Microsoft 
Internet Explorer 9.0 Windows
During Page reloaded unexpectedly during or after null triggered by beforeunload
com.google.jstestdriver.browser.BrowserPanicException: Browser Chrome 
23.0.1271.97 Windows
During Page reloaded unexpectedly during or after null triggered by beforeunload
Unexpected Runner Condition: Failures during test run.
 Use --runnerMode DEBUG for more information.

Original comment by nir...@gmail.com on 31 Dec 2012 at 10:24

GoogleCodeExporter commented 9 years ago
Hello!

I keep having these kind of errors on both IE7&8, BrowserPanicException 
sometimes..

It is quite hard to explain the steps I did to reproduce because it is random. 
Basically I do:
- Start jstd 
- Start IE and start capture
- Launch tests

Sometimes it works sometimes it fails with the BrowserPanicException and this 
LOG:
** Jan 15, 2013 10:37:49 AM com.google.jstestdriver.BrowserPanicResponseStream 
stream **
** SEVERE **: Browser not found : 
{"browserInfo":{"id":1358242450527,"name":"Microsoft Internet 
Explorer","version":"7.0","os":"Windows","uploadSize":50,"serverReceivedHeartbea
t":true,"ready":true},"cause":"Browser unresponsive since 
2013-01-15T09:37:18.961Z during command\u003d 
{\"command\":\"loadTest\",\"parameters\":[\"[{\\\"fileSrc\\\":\\\"/test/com/goog
le/jstestdriver/coverage/javascript/LCOV.js\\\",\\\"basePath\\\":\\\"com/google/
jstestdriver/coverage/javascript/LCOV.js\\\",\\\"timestamp\\\":-1,\\\"length\\\"
:11136},{\\\"fileSrc\\\":\\\"/test/XXXXXXXXXXXXXXX",\\\"basePath\\\":\\\"XXXXXXX
XXXXXXXX",\\\"timestamp\\\":1358241417890,\\\"length\\\":-1},{\\\"fileSrc\\\":\\
\"/test/XXXXXXXXXXXXXXX",\\\"basePath\\\":\\\"XXXXXXXXXXXXXXX",\\\"timestamp\\\"
:1353337040118,\\\"length\\\":-1},
...

...
,{\\\"fileSrc\\\":\\\"/test/XXXXXXXXXXXXXXX",\\\"basePath\\\":\\\"XXXXXXXXXXXXXX
X",\\\"timestamp\\\":1358242277123,\\\"length\\\":-1}]\",\"false\"]}"}
 Exception: com.google.jstestdriver.browser.BrowserPanicException: Browser Microsoft Internet Explorer 7.0 Windows
During
Jan 15, 2013 10:37:49 AM 
com.google.jstestdriver.browser.BrowserActionExecutorAction run
FINE: Finished BrowserActions [com.google.jstestdriver.ResetAction@12cc218, 
com.google.jstestdriver.RunTestsAction@17ae572].
Jan 15, 2013 10:37:49 AM com.google.jstestdriver.ActionRunner runActions
INFO: Finished 
com.google.jstestdriver.browser.BrowserActionExecutorAction@35938e
Jan 15, 2013 10:37:49 AM com.google.jstestdriver.ActionRunner runActions
INFO:
Jan 15, 2013 10:37:49 AM com.google.jstestdriver.Main main
FINE: Error {}
Failures during test run.
Caused by:
com.google.jstestdriver.browser.BrowserPanicException: Browser Microsoft 
Internet Explorer 7.0 Windows
During
        at com.google.jstestdriver.BrowserPanicResponseStream.stream(BrowserPanicResponseStream.java:27)
        at com.google.jstestdriver.AggregatingResponseStreamFactory$AggregatingResponseStream.stream(AggregatingResponseStreamFactory.java:98)
        at com.google.jstestdriver.FileUploader.uploadToTheBrowser(FileUploader.java:203)
        at com.google.jstestdriver.CommandTask.run(CommandTask.java:107)
        at com.google.jstestdriver.JsTestDriverClientImpl.sendCommand(JsTestDriverClientImpl.java:103)
        at com.google.jstestdriver.JsTestDriverClientImpl.runTests(JsTestDriverClientImpl.java:141)
        at com.google.jstestdriver.RunTestsAction.run(RunTestsAction.java:71)
        at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:70)
        at com.google.jstestdriver.browser.BrowserActionRunner.call(BrowserActionRunner.java:37)
        at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
        at java.util.concurrent.FutureTask.run(Unknown Source)
        at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
        at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
        at java.util.concurrent.FutureTask.run(Unknown Source)
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(Unknown Source)
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
        at java.lang.Thread.run(Unknown Source)

        at com.google.jstestdriver.browser.BrowserActionExecutorAction.run(BrowserActionExecutorAction.java:154)
        at com.google.jstestdriver.ActionRunner.runActions(ActionRunner.java:81)
        at com.google.jstestdriver.embedded.JsTestDriverImpl.runConfigurationWithFlags(JsTestDriverImpl.java:342)
        at com.google.jstestdriver.embedded.JsTestDriverImpl.runConfiguration(JsTestDriverImpl.java:233)
        at com.google.jstestdriver.Main.main(Main.java:70)

Original comment by popo...@gmail.com on 15 Jan 2013 at 3:37