diff options
Diffstat (limited to '')
-rw-r--r-- | testing/web-platform/tests/webmessaging/message-channels/dictionary-transferrable.any.js | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/testing/web-platform/tests/webmessaging/message-channels/dictionary-transferrable.any.js b/testing/web-platform/tests/webmessaging/message-channels/dictionary-transferrable.any.js new file mode 100644 index 0000000000..bf49fddb99 --- /dev/null +++ b/testing/web-platform/tests/webmessaging/message-channels/dictionary-transferrable.any.js @@ -0,0 +1,13 @@ +// META: title=basic messagechannel with transfer + +async_test(function(t) { + var channel = new MessageChannel(); + var ab = new ArrayBuffer(1); + channel.port1.postMessage(ab, {transfer: [ab]}); + channel.port2.onmessage = t.step_func( + function(e) { + assert_equals(e.data.byteLength, 1); + t.done(); + }); + channel.port2.start(); +}); |