mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-11-10 13:18:45 +02:00
Automatic update from web-platform-tests Rename audio-output idlharness test for secure context change (#14337) Needed for https://github.com/web-platform-tests/wpt/pull/14069. -- wpt-commits: ef72a20e3dbb89e06df6d193294aed9361f4ad42 wpt-pr: 14337 --HG-- rename : testing/web-platform/tests/audio-output/idlharness.window.js => testing/web-platform/tests/audio-output/idlharness.https.window.js
24 lines
744 B
JavaScript
24 lines
744 B
JavaScript
// META: script=/resources/WebIDLParser.js
|
|
// META: script=/resources/idlharness.js
|
|
|
|
// https://w3c.github.io/mediacapture-output/
|
|
|
|
'use strict';
|
|
|
|
promise_test(async () => {
|
|
const srcs = ['audio-output', 'dom', 'html'];
|
|
const [idl, dom, html] = await Promise.all(
|
|
srcs.map(i => fetch(`/interfaces/${i}.idl`).then(r => r.text())));
|
|
|
|
const idl_array = new IdlArray();
|
|
idl_array.add_idls(idl);
|
|
idl_array.add_dependency_idls(html);
|
|
idl_array.add_dependency_idls(dom);
|
|
self.audio = document.createElement('audio');
|
|
self.video = document.createElement('video');
|
|
idl_array.add_objects({
|
|
HTMLAudioElement: ['audio'],
|
|
HTMLVideoElement: ['video']
|
|
});
|
|
idl_array.test();
|
|
}, 'Test IDL implementation of audio-output API');
|