Closed Bug 863813 Opened 11 years ago Closed 11 years ago

content/media/webspeech/test/head.js: Unexpected events cause tests to be run in parallel

Categories

(Core :: General, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla23

People

(Reporter: ggp, Assigned: ggp)

Details

Attachments

(1 file)

The test harness for speech recognition has a callback for when the test is done, which is sometimes used to perform other tests sequentially.

When a test fails for receiving an unexpected DOM event, this callback gets called twice: once when the failure is detected, and once when all other (expected) events are received. This causes different tests to be launched in parallel, and to interfere with each other.
Comment on attachment 739720 [details] [diff] [review]
Bug 863813: Only call the done function once per test, failure or success

Couldn't you set isDone inside doneFunc and actually there return early if
it has been called already.
Attachment #739720 - Flags: review?(bugs) → review+
Comment on attachment 739720 [details] [diff] [review]
Bug 863813: Only call the done function once per test, failure or success

https://hg.mozilla.org/integration/mozilla-inbound/rev/c0b61756db38
Attachment #739720 - Flags: checkin+
https://hg.mozilla.org/mozilla-central/rev/c0b61756db38
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla23
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: