Last Comment Bug 659559 - test_bug338583.html takes too long
: test_bug338583.html takes too long
Product: Core
Classification: Components
Component: DOM (show other bugs)
: Trunk
: All All
: -- normal (vote)
: mozilla7
Assigned To: Wellington Fernando de Macedo
: Andrew Overholt [:overholt]
Depends on:
Blocks: 338583 FlakyTimeout
  Show dependency treegraph
Reported: 2011-05-24 20:58 PDT by Kyle Huey [:khuey] (Exited; not receiving bugmail, email if necessary)
Modified: 2011-09-16 00:21 PDT (History)
6 users (show)
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---

patch (18.38 KB, patch)
2011-06-04 11:41 PDT, Wellington Fernando de Macedo
bugs: review+
Details | Diff | Splinter Review

Description Kyle Huey [:khuey] (Exited; not receiving bugmail, email if necessary) 2011-05-24 20:58:11 PDT
From a M1 log for a Linux opt build

6844 INFO TEST-END | /tests/content/base/test/test_bug338583.html | finished in 101694ms

The entire M1 run takes 21 minutes, so the EventSource test takes 8% of the total test time to run (including setup and teardown).  This is far too much time.  Looking at the test I see lots of setTimeouts with intervals in the seconds (presumably?  this dynamically calculated stress_factor obscures things) ...
Comment 1 Olli Pettay [:smaug] 2011-05-25 02:04:46 PDT
it takes quite a bit time sure, but certain networking related things are hard to
test without timeouts, at least with the testing framework we have now.
Hard cases are for example testing that we get x messages, not x-1 or x+1.
Another difficult case is to test if that we don't get any messages.

Though, perhaps delayedServerEvents.sjs could test less.
Comment 2 Wellington Fernando de Macedo 2011-05-26 17:50:36 PDT
Hmm. Actually 8% is too much. Perhaps the timeouts could be 10 times lower than as it is right now. I will work on that tomorrow and this weekend.
Comment 3 Wellington Fernando de Macedo 2011-06-04 11:41:40 PDT
Created attachment 537372 [details] [diff] [review]

With this patch my machine took between 10 and 11 seconds to run the test.
Comment 4 Olli Pettay [:smaug] 2011-06-09 05:13:37 PDT
Comment on attachment 537372 [details] [diff] [review]


I'll push this to tryserver before pushing to m-c
Comment 5 Olli Pettay [:smaug] 2011-06-09 05:29:52 PDT
Comment 6 Dão Gottwald [:dao] 2011-06-11 11:36:30 PDT
Comment 7 Ioana (away) 2011-09-16 00:21:01 PDT
test_bug338583.html only takes 10-12 seconds now on all OSs:
7573 INFO TEST-END | /tests/content/base/test/test_bug338583.html | finished in 10717ms
6857 INFO TEST-END | /tests/content/base/test/test_bug338583.html | finished in 10595ms
7573 INFO TEST-END | /tests/content/base/test/test_bug338583.html | finished in 10862ms
7573 INFO TEST-END | /tests/content/base/test/test_bug338583.html | finished in 11255ms

Note You need to log in before you can comment on or make changes to this bug.