diff options
Diffstat (limited to 'testing/web-platform/tests/webmessaging/without-ports/024.html')
-rw-r--r-- | testing/web-platform/tests/webmessaging/without-ports/024.html | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/testing/web-platform/tests/webmessaging/without-ports/024.html b/testing/web-platform/tests/webmessaging/without-ports/024.html new file mode 100644 index 000000000..8d9999459 --- /dev/null +++ b/testing/web-platform/tests/webmessaging/without-ports/024.html @@ -0,0 +1,14 @@ +<!doctype html> +<title>Object cloning: throw an exception if function values encountered</title> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<div id=log></div> +<script> +test(function() { + var obj = { f : function(){}}; + var ch = new MessageChannel(); + ch.port1.onmessage = function(){}; + ch.port2.start(); + assert_throws('DATA_CLONE_ERR', function() { ch.port2.postMessage({obj: obj}); }); +}); +</script> |