Bug 1945965 – remove new tab April Fools logo. r=home-newtab-reviewers,reemhamz
[gecko.git] / dom / midi / tests / test_midi_permission_deny.html
blob8e3043a49a1686980aba77ae92d3168a5c370c43
1 <html>
2 <head>
3 <title>WebMIDI Listener Test</title>
4 <script src="/tests/SimpleTest/SimpleTest.js"></script>
5 <script type="application/javascript" src="MIDITestUtils.js"></script>
6 </head>
8 <body onload="runTests()">
9 <script class="testbody" type="application/javascript">
10 SimpleTest.waitForExplicitFinish();
12 async function runTests() {
13 await MIDITestUtils.permissionSetup(false);
14 // Request access without sysex.
15 try {
16 await navigator.requestMIDIAccess({ "sysex": false });
17 ok(false, "MIDI Access Request Deny failed");
18 SimpleTest.finish();
19 } catch (ex) {
20 ok(true, "MIDI Access Request Deny successful!");
21 SimpleTest.finish();
24 </script>
25 </body>
26 </html>