Bug 1593244 avoid await and async function so that setup() catches undefined context.audioWorklet r=padenot

Differential Revision: https://phabricator.services.mozilla.com/D51556

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Karl Tomlinson 2019-11-04 17:28:32 +00:00
parent b5f917254e
commit 407ce752f5

View file

@ -13,9 +13,9 @@
const audit = Audit.createTaskRunner();
const context = new AudioContext();
setup(async function () {
await context.audioWorklet.addModule(
'processors/channel-count-processor.js');
setup(function () {
context.audioWorklet.addModule(
'processors/channel-count-processor.js').then(() => audit.run());
// Test if the output channe count dynamically changes if the input
// and output is 1.
@ -74,8 +74,6 @@
// if the specified channel count is kept correctly.
node.connect(context.destination);
});
audit.run();
});
</script>
</body>