blob: 28540a0679e4394dd9c40907b0a8eeb613eca2ae [file] [log] [blame]
Tests navigator.requestMIDIAccess.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS requestMIDIAccess() succeeded with access [object MIDIAccess].
PASS access.sysexEnabled is defined.
PASS access.sysexEnabled is false
PASS access.inputs.size is 1
PASS access.outputs.size is 1
for (var input of inputs.values())
PASS input.id is "MockInputID"
PASS input.manufacturer is "MockInputManufacturer"
PASS input.name is "MockInputName"
PASS input.version is "MockInputVersion"
for (var input of inputs.keys())
PASS inputKey is "MockInputID"
for (var input of inputs.entries())
PASS entry[0] is inputKey
PASS entry[1] is input
for (var input of inputs)
PASS entry[0] is inputKey
PASS entry[1] is input
PASS inputs.has('MockInputID') is true
PASS inputs.has('MockOutputID') is false
PASS inputs.get('MockInputID') is input
PASS inputs.get('MockOutputID') is undefined.
for (var output of outputs.values())
PASS output.id is "MockOutputID"
PASS output.manufacturer is "MockOutputManufacturer"
PASS output.name is "MockOutputName"
PASS output.version is "MockOutputVersion"
for (var output of outputs.keys())
PASS outputKey is "MockOutputID"
for (var output of outputs.entries())
PASS entry[0] is outputKey
PASS entry[1] is output
for (var output of outputs)
PASS entry[0] is outputKey
PASS entry[1] is output
PASS outputs.has('MockOutputID') is true
PASS outputs.has('MockInputID') is false
PASS outputs.get('MockOutputID') is output
PASS outputs.get('MockInputID') is undefined.
PASS a note on message is sent without timestamp
PASS a note on message is sent with timestamp
PASS output.send([0xfff, 0x45, 0x7f]) threw exception TypeError: Failed to execute 'send' on 'MIDIOutput': The value at index 0 (4095) is greater than 0xFF..
PASS output.send([0xf0, 0x45, 0xf7]) threw exception InvalidAccessError: Failed to execute 'send' on 'MIDIOutput': System exclusive message is not allowed at index 0 (240)..
PASS requestMIDIAccess() was correctly blocked for System Exclusive access with error [object DOMError].
PASS successfullyParsed is true
TEST COMPLETE