| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 <script src="../resources/js-test.js"></script> | 4 <script src="../resources/js-test.js"></script> |
| 5 <script src="../http/tests/resources/permissions-helper.js"></script> | 5 <script src="../http/tests/resources/permissions-helper.js"></script> |
| 6 </head> | 6 </head> |
| 7 <body> | 7 <body> |
| 8 <script> | 8 <script> |
| 9 | 9 |
| 10 description("Test if midimessage event handler work."); | 10 description("Test if midimessage event handler work."); |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 66 var output = a.outputs.values().next().value; | 66 var output = a.outputs.values().next().value; |
| 67 for (var i = 0; i < testData.length; ++i) | 67 for (var i = 0; i < testData.length; ++i) |
| 68 output.send(testData[i]); | 68 output.send(testData[i]); |
| 69 }, function () { | 69 }, function () { |
| 70 testFailed("requestMIDIAccess() return an error."); | 70 testFailed("requestMIDIAccess() return an error."); |
| 71 reject(); | 71 reject(); |
| 72 }); | 72 }); |
| 73 }); | 73 }); |
| 74 } | 74 } |
| 75 | 75 |
| 76 PermissionsHelper.setPermission('midi-sysex', 'granted').then(function() { | 76 Promise.all([PermissionsHelper.setPermission('midi', 'granted'), |
| 77 PermissionsHelper.setPermission('midi-sysex', 'granted')]).then(fun
ction() { |
| 77 test(false).then(test.bind(null, true)).then(finishJSTest, finishJSTest); | 78 test(false).then(test.bind(null, true)).then(finishJSTest, finishJSTest); |
| 78 }); | 79 }); |
| 79 | 80 |
| 80 </script> | 81 </script> |
| 81 </body> | 82 </body> |
| 82 </html> | 83 </html> |
| OLD | NEW |