Closed Bug 1611028 Opened 4 years ago Closed 4 years ago

Enable `dom.media.mediasession.enabled` for testing

Categories

(Core :: Audio/Video: Playback, task, P2)

task

Tracking

()

RESOLVED WONTFIX

People

(Reporter: alwu, Assigned: alwu)

References

Details

Attachments

(1 obsolete file)

As media session is an webidl interface controlled by the value of the pref dom.media.mediasession.enabled, and I found that in some situation, we can't get that interface even if the pref has been enabled.

I guess it might be related with the order of initialization of DOM objects, which might involve too much DOM details. So I'm going to take the simplest workaround, which is to enable this pref on testing environment, that can ensure that we always get the media session interface.

We should remove this workaround when we decide to expose media session without checking the pref.

Blocks: 1611029

As media session is an webidl interface controlled by the value of the pref dom.media.mediasession.enabled, and I found that in some situation (in mochitest), we can't get that interface even if the pref has been enabled.

I guess it might be related with the order of initialization of DOM objects, which might involve too much DOM details. So I'm going to take the simplest workaround, which is to enable this pref on testing environment, that can ensure that we always get the media session interface.

Pushed by alwu@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/cb295b86edd2
enable the pref 'dom.media.mediasession.enabled' for testing by default. r=chunmin

Push with failures: https://treeherder.mozilla.org/#/jobs?repo=autoland&group_state=expanded&selectedJob=286090853&resultStatus=testfailed%2Cbusted%2Cexception&classifiedState=unclassified&revision=cb295b86edd25fc8f7ce716c960506322e23c875&searchStr=android%2C7.0%2Cx86-64%2Copt%2Cmochitests%2Ctest-android-em-7.0-x86_64%2Fopt-geckoview-mochitest-e10s-4%2Cm%284%29

Failure log: https://treeherder.mozilla.org/logviewer.html#?job_id=286090853&repo=autoland

Backout link: https://hg.mozilla.org/integration/autoland/rev/fc97efc614bf52db6519e2c831bf52da5f80f57a

[task 2020-01-23T03:42:11.653Z] 03:42:11 INFO - 1833 INFO TEST-PASS | dom/tests/mochitest/general/test_interfaces.html | IDBVersionChangeEvent is exposed as an own property on the window but has no property descriptor in the global scope
[task 2020-01-23T03:42:11.653Z] 03:42:11 INFO - Buffered messages finished
[task 2020-01-23T03:42:11.654Z] 03:42:11 WARNING - 1834 INFO TEST-UNEXPECTED-FAIL | dom/tests/mochitest/general/test_interfaces.html | If this is failing: DANGER, are you sure you want to expose the new interface MediaMetadata to all webpages as a property on the window? Do not make a change to this file without a review from a DOM peer for that specific change!!! (or a JS peer for changes to ecmaGlobals)
[task 2020-01-23T03:42:11.654Z] 03:42:11 INFO - SimpleTest.ok@SimpleTest/SimpleTest.js:277:18
[task 2020-01-23T03:42:11.654Z] 03:42:11 INFO - runTest@dom/tests/mochitest/general/test_interfaces.js:1464:7
[task 2020-01-23T03:42:11.654Z] 03:42:11 INFO - @dom/tests/mochitest/general/test_interfaces.js:1503:1
[task 2020-01-23T03:42:11.655Z] 03:42:11 INFO - 1835 INFO TEST-PASS | dom/tests/mochitest/general/test_interfaces.html

There are also these wpt failures: https://treeherder.mozilla.org/logviewer.html#?job_id=286093161&repo=autoland

Flags: needinfo?(alwu)

OK, it seems not a good idea to turn the pref on by default in testing, I will close this bug and file another bug to handle the issue I got.

Status: NEW → RESOLVED
Closed: 4 years ago
Flags: needinfo?(alwu)
Resolution: --- → WONTFIX
Attachment #9122539 - Attachment is obsolete: true
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: