Some Gaia unit tests misuse Promise static methods

RESOLVED FIXED in FxOS-S11 (13Nov)

Status

Firefox OS
Gaia
RESOLVED FIXED
2 years ago
2 years ago

People

(Reporter: bz, Assigned: bz)

Tracking

unspecified
FxOS-S11 (13Nov)
ARM
Gonk (Firefox OS)

Firefox Tracking Flags

(blocking-b2g:2.5?)

Details

Attachments

(1 attachment)

In Gecko right now, Promise.resolve.call(undefined, foo) has the same behavior as Promise.resolve.call(Promise, foo), and some Gaia tests rely on that.  However per spec the former should throw while the latter should work.  As a result, fixing bug 1170760 breaks Gaia unit tests.
Created attachment 8684914 [details] [review]
[gaia] bzbarsky:fix-promise-abuses > mozilla-b2g:master
Attachment #8684914 - Flags: review?(timdream)
Attachment #8684914 - Flags: review?(timdream) → review+
Thanks bz!
Keywords: checkin-needed
https://github.com/mozilla-b2g/gaia/commit/ac4003f6969a1fe705caf1ecbfb7275faee39cd7
Status: NEW → RESOLVED
Last Resolved: 2 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → FxOS-S11 (13Nov)
[Blocking Requested - why for this release]:

v2.5 would probably need this patch to fix the test failure, too.
blocking-b2g: --- → 2.5?
Flags: needinfo?(cbook)

Comment 5

2 years ago
@Tim,
Would this Promise misusage issue affect Gaia v2.5 ?
If yes, it may need to be uplifted to v2.5.
Could you take a look at it?
thank you.
Flags: needinfo?(timdream)
Bug 1170760 only reaches Gecko 45, so it should not affect v2.5, I think.
Assignee: nobody → bzbarsky
Flags: needinfo?(timdream)
would need approval for 2.5
Flags: needinfo?(mpotharaju)
Flags: needinfo?(jocheng)
Flags: needinfo?(cbook)
As it doesn't affect 2.5. We do not need a 2.5 uplift. 

Thanks
Flags: needinfo?(mpotharaju)

Comment 9

2 years ago
Agree with Mahe
Flags: needinfo?(jocheng)
You need to log in before you can comment on or make changes to this bug.