Closed Bug 1651386 Opened 4 years ago Closed 4 years ago

[wpt-sync] Sync PR 24513 - Abstract portal activation handling to avoid hack of making a fake promise.

Categories

(Testing :: web-platform-tests, task, P4)

task

Tracking

(firefox80 fixed)

RESOLVED FIXED
mozilla80
Tracking Status
firefox80 --- fixed

People

(Reporter: mozilla.org, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 24513 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/24513
Details from upstream follow.

Jeremy Roman <jbroman@chromium.org> wrote:

Abstract portal activation handling to avoid hack of making a fake promise.

This is somewhat verbose, but allows us to avoid the unhandled rejection
being visible to script without having to make this hack even worse.

Instead of actually calling activate(), this mirrors the spec structure
by simply calling to underlying logic, passing a resolver where it makes
sense and not (in this case, passing a substitute object) where it
doesn't.

Bug: 1102081
Change-Id: I0eecf253928bfce39afcddccf54e9bc6f6c0d549
Reviewed-on: https://chromium-review.googlesource.com/2285340
WPT-Export-Revision: fbbaa0220eda0eba58c2435fcb482c2e94aabc6e

PR 24513 applied with additional changes from upstream: 03d89c92bba52de611854f29373ba2c062ea0729

CI Results

Ran 0 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 1 tests and 3 subtests

Status Summary

Firefox

OK : 1
FAIL: 3

Chrome

OK : 1
FAIL: 3

Safari

OK : 1
FAIL: 3

Links

GitHub PR Head
GitHub PR Base

Details

New Tests That Don't Pass

/portals/portal-activate-default.html
Clicking shouldn't activate if prevented.: FAIL (Chrome: FAIL, Safari: FAIL)
Clicking should activate with undefined data.: FAIL (Chrome: FAIL, Safari: FAIL)
Failed activation should not surface as an unhandled promise rejection.: FAIL (Chrome: FAIL, Safari: FAIL)

Pushed by wptsync@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/7036bc5802bf
[wpt PR 24513] - Abstract portal activation handling to avoid hack of making a fake promise., a=testonly
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla80
You need to log in before you can comment on or make changes to this bug.