Closed
Bug 1093931
Opened 10 years ago
Closed 10 years ago
Loop mocha tests with DOM Promises have failure modes that are hard to understand/debug
Categories
(Hello (Loop) :: Client, defect)
Tracking
(Not tracked)
People
(Reporter: dmosedale, Assigned: dmosedale)
Details
Attachments
(1 file)
68.55 KB,
patch
|
standard8
:
review+
|
Details | Diff | Splinter Review |
Rather than showing how the test failed, they just time out, and it's hard to figure out why. Tbpl/Treeherder logs would be fairly useless in the case of failures here. The fix is to upgrade Mocha to version 2.0.1. The important change is that newer versions of Mocha support promises natively: you no longer use function(done) to declare the test as async. Instead, you just have the test return the last promise on the chain.
Assignee | ||
Comment 1•10 years ago
|
||
Assignee | ||
Comment 2•10 years ago
|
||
Comment on attachment 8517058 [details] [diff] [review] [landed fx-team] Update Loop mocha unit test framework to v2.0.1, which supports Promises I've just fixed up the Promise uses that we introduced in multiplexGum_test.js. It's not clear from a quick skim that the other existing promise uses in the tree would benefit as much from being tweaked to the new API, though it's certainly possible that they will. This release of Mocha includes a wide variety of fixes and a few enhancements, everything, back to and include 1.18 in the History file: https://github.com/mochajs/mocha/blob/2.0.1/History.md
Attachment #8517058 -
Flags: review?(standard8)
Assignee | ||
Comment 3•10 years ago
|
||
Note that the reason there is no mocha.css diff included in the patch is because that file is literally unchanged since 1.17.1.
Updated•10 years ago
|
Attachment #8517058 -
Flags: review?(standard8) → review+
Assignee | ||
Comment 4•10 years ago
|
||
https://hg.mozilla.org/integration/fx-team/rev/1b52d3719b7f
Assignee | ||
Updated•10 years ago
|
Attachment #8517058 -
Attachment description: Update Loop mocha unit test framework to v2.0.1, which supports Promises → [landed fx-team] Update Loop mocha unit test framework to v2.0.1, which supports Promises
https://hg.mozilla.org/mozilla-central/rev/1b52d3719b7f
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla36
Updated•10 years ago
|
Iteration: --- → 36.3
You need to log in
before you can comment on or make changes to this bug.
Description
•