Closed Bug 1139094 Opened 9 years ago Closed 9 years ago

[steeplechase] tests are broken in multiple places

Categories

(Core :: WebRTC, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla39
Tracking Status
firefox38 --- fixed
firefox39 --- fixed

People

(Reporter: drno, Assigned: drno)

Details

Attachments

(1 file, 1 obsolete file)

Steeplechase tests in the QA lab are currently broken in multiple places.
Assignee: nobody → drno
This fixes:

- steeplechase hangs because local/remote tracks IDs don't get properly transferred to the far end
- steeplechase hangs because pc.js executes code from network.js before test.js got loaded, which results in 'info' not being defined
- steeplechase timeouts throw errors about undefined teardown() method
- steeplechase tests sometimes fail because of RTCP timestamps differences
Attachment #8572432 - Flags: review?(martin.thomson)
Attachment #8572432 - Flags: review?(docfaraday)
Comment on attachment 8572432 [details] [diff] [review]
bug_1139094_steeplechase_tests.patch

Review of attachment 8572432 [details] [diff] [review]:
-----------------------------------------------------------------

Just a nit.

::: dom/media/tests/mochitest/pc.js
@@ +1778,5 @@
>  }
>  
>  function runNetworkTest(testFunction) {
>    return scriptsReady
> +    .then(() => runTestWhenReady(options => {startNetworkAndTest(); testFunction(options);}));

Let's throw some newlines in here.
Attachment #8572432 - Flags: review?(docfaraday) → review+
Comment on attachment 8572432 [details] [diff] [review]
bug_1139094_steeplechase_tests.patch

Review of attachment 8572432 [details] [diff] [review]:
-----------------------------------------------------------------

I trust that you can handle the comment here.

::: dom/media/tests/mochitest/templates.js
@@ +143,5 @@
>    function PC_SETUP_SIGNALING_CLIENT(test) {
>      if (test.steeplechase) {
>        setTimeout(() => {
>          ok(false, "PeerConnectionTest timed out");
> +        throw new Error('PeerConnectionTest timed out after 30s');

Sure this triggers onerror, but this isn't going to get caught properly.  You need to roll this failure into the Promise that this step returns.

var timeout = new Promise((res, rej) => setTimeout(rej, 30000));
return Promise.race([theRealOutcome, timeout]);

With the timeout promise only being added to the race if things are under steeplechase.
Attachment #8572432 - Flags: review?(martin.thomson) → review+
Attachment #8572432 - Attachment is obsolete: true
Attachment #8573601 - Flags: review?(martin.thomson)
Attachment #8573601 - Flags: review?(martin.thomson) → review+
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/3d92a01ab497
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla39
Try run on Aurora: https://treeherder.mozilla.org/#/jobs?repo=try&revision=f503e28ff39e

Reminder to myself to check for the results
Flags: needinfo?(drno)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: