Title: [253451] trunk/LayoutTests
Revision
253451
Author
[email protected]
Date
2019-12-12 16:02:51 -0800 (Thu, 12 Dec 2019)

Log Message

Re-sync webmessaging web-platform-tests from upstream
https://bugs.webkit.org/show_bug.cgi?id=205178

Reviewed by Alex Christensen.

LayoutTests/imported/w3c:

Re-sync webmessaging web-platform-tests from upstream ab28e18f067f17a.

* web-platform-tests/webmessaging/*: Updated

LayoutTests:

* TestExpectations:

Modified Paths

Added Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (253450 => 253451)


--- trunk/LayoutTests/ChangeLog	2019-12-12 23:53:40 UTC (rev 253450)
+++ trunk/LayoutTests/ChangeLog	2019-12-13 00:02:51 UTC (rev 253451)
@@ -1,5 +1,14 @@
 2019-12-12  Chris Dumez  <[email protected]>
 
+        Re-sync webmessaging web-platform-tests from upstream
+        https://bugs.webkit.org/show_bug.cgi?id=205178
+
+        Reviewed by Alex Christensen.
+
+        * TestExpectations:
+
+2019-12-12  Chris Dumez  <[email protected]>
+
         Regression(r253394) swipe/basic-cached-back-swipe.html is timing out on iOS
         https://bugs.webkit.org/show_bug.cgi?id=205173
 

Modified: trunk/LayoutTests/TestExpectations (253450 => 253451)


--- trunk/LayoutTests/TestExpectations	2019-12-12 23:53:40 UTC (rev 253450)
+++ trunk/LayoutTests/TestExpectations	2019-12-13 00:02:51 UTC (rev 253451)
@@ -336,6 +336,7 @@
 imported/w3c/web-platform-tests/cors/image-tainting-in-cross-origin-iframe.sub.html [ Skip ]
 imported/w3c/web-platform-tests/dom/events/EventListener-incumbent-global-1.sub.html [ Skip ]
 imported/w3c/web-platform-tests/dom/events/EventListener-incumbent-global-2.sub.html [ Skip ]
+imported/w3c/web-platform-tests/webmessaging/broadcastchannel/origin.window.html [ Skip ]
 
 # Newly imported WPT ref tests failures.
 imported/w3c/web-platform-tests/html/dom/elements/requirements-relating-to-bidirectional-algorithm-formatting-characters/dir-isolation-001a.html [ ImageOnlyFailure ]

Modified: trunk/LayoutTests/imported/w3c/ChangeLog (253450 => 253451)


--- trunk/LayoutTests/imported/w3c/ChangeLog	2019-12-12 23:53:40 UTC (rev 253450)
+++ trunk/LayoutTests/imported/w3c/ChangeLog	2019-12-13 00:02:51 UTC (rev 253451)
@@ -1,5 +1,16 @@
 2019-12-12  Chris Dumez  <[email protected]>
 
+        Re-sync webmessaging web-platform-tests from upstream
+        https://bugs.webkit.org/show_bug.cgi?id=205178
+
+        Reviewed by Alex Christensen.
+
+        Re-sync webmessaging web-platform-tests from upstream ab28e18f067f17a.
+
+        * web-platform-tests/webmessaging/*: Updated
+
+2019-12-12  Chris Dumez  <[email protected]>
+
         window.AudioContext / window.OfflineAudioContext should not be enumerable
         https://bugs.webkit.org/show_bug.cgi?id=205163
 

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_transfer_xsite_incoming_messages.window-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_transfer_xsite_incoming_messages.window-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_transfer_xsite_incoming_messages.window-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,5 @@
+
+PASS Tasks enqueued on the port-message-queue of an enabled port,
+  are transferred along with the port, when the transfer happens in the same task
+  during which postMessage is called 
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_transfer_xsite_incoming_messages.window.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_transfer_xsite_incoming_messages.window.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_transfer_xsite_incoming_messages.window.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1 @@
+<!-- This file is required for WebKit test infrastructure to run the templated test -->
\ No newline at end of file

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_transfer_xsite_incoming_messages.window.js (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_transfer_xsite_incoming_messages.window.js	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_transfer_xsite_incoming_messages.window.js	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,32 @@
+// META: script=/common/get-host-info.sub.js
+
+async_test(function(t) {
+  var channel1 = new MessageChannel();
+  var host = get_host_info();
+  let iframe = document.createElement('iframe');
+  iframe.src = "" + "/webmessaging/support/ChildWindowPostMessage.htm";
+  document.body.appendChild(iframe);
+  var TARGET = document.querySelector("iframe").contentWindow;
+  iframe._onload_ = t.step_func(function() {
+    // Enable the port.
+    channel1.port1._onmessage_ = t.step_func(function (evt) {
+      assert_equals(Number(evt.data), 0);
+
+      // Send a message, expecting it to be received in the iframe.
+      channel1.port2.postMessage(1)
+
+      // Transfer the port.
+      TARGET.postMessage("ports", "*", [channel1.port1]);
+    });
+
+    // Send a message, expecting it to be received here.
+    channel1.port2.postMessage(0)
+
+    channel1.port2._onmessage_ = t.step_func(function (evt) {
+        assert_equals(Number(evt.data), 1);
+        t.done();
+      });
+  });
+}, `Tasks enqueued on the port-message-queue of an enabled port,
+  are transferred along with the port, when the transfer happens in the same task
+  during which postMessage is called`);

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+PASS An entangled port transferred to the same origin receives messages in order 
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1 @@
+<!-- This file is required for WebKit test infrastructure to run the templated test -->
\ No newline at end of file

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any.js (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any.js	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any.js	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,36 @@
+async_test(function(t) {
+    var channel1 = new MessageChannel();
+    var channel2 = new MessageChannel();
+
+     // One, send a message.
+     channel1.port1.postMessage(1);
+
+     // Two, transfer both ports.
+     channel2.port1.postMessage("transfer", [channel1.port1]);
+     channel2.port1.postMessage("transfer", [channel1.port2]);
+
+     var transfer_counter = 0;
+     var sender;
+     channel2.port2._onmessage_ = t.step_func(function (evt) {
+         if (transfer_counter == 0) {
+             sender = evt.ports[0];
+             transfer_counter = 1;
+         } else {
+             sender.postMessage(2);
+             var counter = 0;
+             evt.ports[0]._onmessage_ = t.step_func(function (evt) {
+                 if (counter == 0) {
+                     assert_equals(evt.data, 1);
+                     counter = 1;
+                 } else if (counter == 1) {
+                     assert_equals(evt.data, 2);
+                     counter = 2;
+                 } else {
+                     assert_equals(evt.data, 3);
+                     t.done();
+                 }
+             });
+             sender.postMessage(3);
+         }
+      });
+}, "An entangled port transferred to the same origin receives messages in order");

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any.worker-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any.worker-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any.worker-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+PASS An entangled port transferred to the same origin receives messages in order 
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any.worker.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any.worker.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any.worker.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1 @@
+<!-- This file is required for WebKit test infrastructure to run the templated test -->
\ No newline at end of file

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,4 @@
+
+PASS When transferring a non-enabled port mutiple times,
+    incoming messages sent at various transfer steps are received in order upon enablement. 
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1 @@
+<!-- This file is required for WebKit test infrastructure to run the templated test -->
\ No newline at end of file

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any.js (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any.js	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any.js	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,32 @@
+async_test(function(t) {
+  var channel1 = new MessageChannel();
+  var channel2 = new MessageChannel();
+  var channel3 = new MessageChannel();
+  channel2.port2._onmessage_ = t.step_func(function (evt) {
+    channel3.port1._onmessage_ = t.step_func(function (evt) {
+      var counter = 0;
+      evt.ports[0]._onmessage_ = t.step_func(function (evt) {
+        if (counter == 0) {
+          assert_equals(evt.data, "First");
+          counter = 1;
+        } else if (counter == 1) {
+          assert_equals(evt.data, "Second");
+          counter = 2;
+        } else if (counter == 2) {
+          assert_equals(evt.data, "Third");
+          counter = 3;
+        } else if (counter == 3) {
+          assert_equals(evt.data, "Fourth");
+          t.done();
+        }
+      });
+      channel1.port2.postMessage("Fourth");
+    });
+    channel1.port2.postMessage("Second");
+    channel1.port2.postMessage("Third");
+    channel3.port2.postMessage("2", evt.ports);
+  });
+  channel1.port2.postMessage("First");
+  channel2.port1.postMessage("1", [channel1.port1]);
+}, `When transferring a non-enabled port mutiple times,
+    incoming messages sent at various transfer steps are received in order upon enablement.`);

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any.worker-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any.worker-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any.worker-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,4 @@
+
+PASS When transferring a non-enabled port mutiple times,
+    incoming messages sent at various transfer steps are received in order upon enablement. 
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any.worker.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any.worker.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any.worker.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1 @@
+<!-- This file is required for WebKit test infrastructure to run the templated test -->
\ No newline at end of file

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,4 @@
+
+PASS When transferring a port,
+    outgoing messages sent at each transfer step are received in order by the entangled port. 
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1 @@
+<!-- This file is required for WebKit test infrastructure to run the templated test -->
\ No newline at end of file

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any.js (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any.js	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any.js	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,35 @@
+
+async_test(function(t) {
+  var channel1 = new MessageChannel();
+  var channel2 = new MessageChannel();
+  var channel3 = new MessageChannel();
+  channel2.port2._onmessage_ = t.step_func(function (evt) {
+    evt.ports[0].postMessage("Second");
+    evt.ports[0].postMessage("Third");
+    channel3.port1._onmessage_ = t.step_func(function (evt) {
+      evt.ports[0].postMessage("Fourth");
+    });
+    channel3.port2.postMessage("2", evt.ports);
+  });
+  channel1.port1.postMessage("First");
+  channel2.port1.postMessage("1", [channel1.port1]);
+  var counter = 0;
+  channel1.port2._onmessage_ = t.step_func(function (evt) {
+    if (counter == 0) {
+      assert_equals(evt.data, "First");
+      counter = 1;
+    } else if (counter == 1) {
+      assert_equals(evt.data, "Second");
+      counter = 2;
+    }
+    else if (counter == 2) {
+      assert_equals(evt.data, "Third");
+      counter = 3;
+    }
+    else if (counter == 3) {
+      assert_equals(evt.data, "Fourth");
+      t.done();
+    }
+  });
+}, `When transferring a port,
+    outgoing messages sent at each transfer step are received in order by the entangled port.`);

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any.worker-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any.worker-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any.worker-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,4 @@
+
+PASS When transferring a port,
+    outgoing messages sent at each transfer step are received in order by the entangled port. 
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any.worker.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any.worker.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any.worker.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1 @@
+<!-- This file is required for WebKit test infrastructure to run the templated test -->
\ No newline at end of file

Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/META.yml (253450 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/META.yml	2019-12-12 23:53:40 UTC (rev 253450)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/META.yml	2019-12-13 00:02:51 UTC (rev 253451)
@@ -1,6 +1,6 @@
+spec: https://html.spec.whatwg.org/multipage/web-messaging.html
 suggested_reviewers:
   - zqzhang
-  - aogilvie
   - jdm
   - mkruisselbrink
   - annevk

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/broadcastchannel/origin.window-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/broadcastchannel/origin.window-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/broadcastchannel/origin.window-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,6 @@
+Blocked access to external URL http://xn--n8j6ds53lwwkrqhv28a.localhost:8800/webmessaging/broadcastchannel/resources/origin.html
+
+Harness Error (TIMEOUT), message = null
+
+TIMEOUT Serialization of BroadcastChannel origin Test timed out
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/broadcastchannel/origin.window.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/broadcastchannel/origin.window.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/broadcastchannel/origin.window.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1 @@
+<!-- This file is required for WebKit test infrastructure to run the templated test -->
\ No newline at end of file

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/dictionary-transferrable-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/dictionary-transferrable-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/dictionary-transferrable-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+FAIL basic messagechannel with transfer Type error
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/dictionary-transferrable.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/dictionary-transferrable.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/dictionary-transferrable.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,18 @@
+<!doctype html>
+<title>basic messagechannel with transfer</title>
+<script src=""
+<script src=""
+<div id="log"></div>
+<script>
+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();
+});
+</script>

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/user-activation.tentative-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/user-activation.tentative-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/user-activation.tentative-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+FAIL user activation messagechannel test Type error
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/user-activation.tentative.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/user-activation.tentative.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/user-activation.tentative.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,26 @@
+<!doctype html>
+<title>user activation messagechannel test</title>
+<script src=""
+<script src=""
+<div id="log"></div>
+<script>
+async_test(function(t) {
+  var channel = new MessageChannel();
+  channel.port1.postMessage(1, {includeUserActivation: true});
+  channel.port1.postMessage(2);
+  var expected_data = 1;
+  channel.port2._onmessage_ = t.step_func(
+    function(e) {
+      assert_equals(e.data, expected_data);
+      expected_data++;
+      if (e.data == 1) {
+        assert_false(e.userActivation.isActive);
+        assert_false(e.userActivation.hasBeenActive);
+      } else {
+        assert_equals(e.userActivation, null);
+        t.done();
+      }
+    });
+  channel.port2.start();
+});
+</script>

Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/w3c-import.log (253450 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/w3c-import.log	2019-12-12 23:53:40 UTC (rev 253450)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/w3c-import.log	2019-12-13 00:02:51 UTC (rev 253451)
@@ -21,4 +21,7 @@
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/004-2.html
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/004.html
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/close.html
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/dictionary-transferrable.html
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/user-activation.tentative.html
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/worker-post-after-close.html
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/worker.html

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/worker-post-after-close-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/worker-post-after-close-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/worker-post-after-close-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+PASS MessageChannel/MessagePort should not work after a worker self.close() 
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/worker-post-after-close.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/worker-post-after-close.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/message-channels/worker-post-after-close.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,36 @@
+<!DOCTYPE html>
+<meta charset=utf-8>
+<link rel="help" href=""
+<script src=""
+<script src=""
+<script>
+
+async_test(t => {
+  function workerCode() {
+    _onmessage_ = function(e) {
+      close();
+      var mc = new MessageChannel();
+      mc.port1._onmessage_ = function() {
+        postMessage("message received!");
+      }
+      mc.port2.postMessage(42);
+      postMessage("done");
+    }
+  }
+
+  var workerBlob = new Blob([workerCode.toString() + ";workerCode();"], {type:"application/_javascript_"});
+
+  var w = new Worker(URL.createObjectURL(workerBlob));
+  w.postMessage('');
+  w._onmessage_ = function(e) {
+    if (e.data == "done") {
+      setTimeout(function() {
+        t.done();
+      }, 250);
+    } else {
+      assert_true(false, "A wrong message has been received!");
+    }
+  }
+}, 'MessageChannel/MessagePort should not work after a worker self.close()');
+
+</script>

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_MessagePorts_xsite.sub.window-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_MessagePorts_xsite.sub.window-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_MessagePorts_xsite.sub.window-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+FAIL Test Description: postMessage to cross-site iframe with MessagePort array containing 100 ports. The string did not match the expected pattern.
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_MessagePorts_xsite.sub.window.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_MessagePorts_xsite.sub.window.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_MessagePorts_xsite.sub.window.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1 @@
+<!-- This file is required for WebKit test infrastructure to run the templated test -->
\ No newline at end of file

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_MessagePorts_xsite.sub.window.js (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_MessagePorts_xsite.sub.window.js	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_MessagePorts_xsite.sub.window.js	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,66 @@
+// META: script=/common/get-host-info.sub.js
+
+async_test(function(t) {
+    var host = get_host_info();
+    var noteSameSiteURL = host.HTTP_NOTSAMESITE_ORIGIN + "/webmessaging/support/ChildWindowPostMessage.htm";
+    var TOTALPORTS = 100;
+    var LocalPorts = [];
+    var RemotePorts = [];
+    var PassedResult = 0;
+    var sum = 0;
+    let iframe = document.createElement('iframe');
+    iframe.src = ""
+    document.body.appendChild(iframe);
+    var TARGET = document.querySelector("iframe").contentWindow;
+    iframe._onload_ = t.step_func(function() {
+        assert_own_property(window, "MessageChannel", "window");
+
+        var channels = [];
+
+        for (var i=0; i<TOTALPORTS; i++)
+        {
+            channels[i] = new MessageChannel();
+            LocalPorts[i] = channels[i].port1;
+            LocalPorts[i].foo = i;
+            RemotePorts[i] = channels[i].port2;
+
+            LocalPorts[i]._onmessage_ = t.step_func(function(e)
+            {
+                assert_equals(e.target.foo, e.data);
+
+                PassedResult++;
+                sum += e.data;
+
+                if (PassedResult == TOTALPORTS)
+                {
+                    assert_equals(sum, 4950);
+                    t.done();
+                }
+            });
+        }
+        // Sending in two batches, to test the two postMessage variants.
+        var firstBatch = RemotePorts.slice(0, 50);
+        var secondBatch = RemotePorts.slice(50, 100);
+        TARGET.postMessage("ports", "*", firstBatch);
+        TARGET.postMessage("ports", {targetOrigin: '*', transfer: secondBatch});
+    });
+    var counter = 0;
+    window._onmessage_ = function(e)
+    {
+        if (e.data ="" "ports")
+        {
+            if (counter == 0) {
+                for (var i=0; i<51; i++)
+                {
+                    LocalPorts[i].postMessage(LocalPorts[i].foo);
+                }
+                counter = 1;
+            } else {
+                for (var i=51; i<100; i++)
+                {
+                    LocalPorts[i].postMessage(LocalPorts[i].foo);
+                }
+            }
+        }
+    }
+}, "Test Description: postMessage to cross-site iframe with MessagePort array containing 100 ports.");

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/support/ChildWindowPostMessage.htm (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/support/ChildWindowPostMessage.htm	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/support/ChildWindowPostMessage.htm	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,58 @@
+<!DOCTYPE html>
+<html>
+<head>
+    <title> Child window for Web Messaging tests </title>
+</head>
+<body>
+    <script>
+        if (window.opener)
+        {
+            window._onload_ = function()
+            {
+                try
+                {
+                    window.opener.postMessage("MSG_ONLOAD_FIRED", "*");
+                }
+                catch(ex)
+                {
+                    window.close();
+                }
+            }
+        }
+
+        window._onmessage_ = function(e)
+        {
+            try
+            {
+                if (typeof(e.data) == "object" && typeof(e.data.test) == "string")
+                {
+                    eval(e.data.test);
+                }
+                else if (e.data == "*" || e.data == "/")
+                {
+                    e.source.postMessage(e.data, e.data);
+                }
+                else
+                {
+                    e.source.postMessage(e.data, e.origin);
+                }
+
+                if (e.data == "ports")
+                {
+                    var total = e.ports.length;
+                    for (var i=0; i<total; i++)
+                    {
+                        e.ports[i]._onmessage_ = function (evt)
+                        {
+                            evt.target.postMessage(evt.data);
+                        }
+                    }
+                }
+            }
+            catch(ex)
+            {
+            }
+        }
+    </script>
+</body>
+</html>

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/support/compare.js (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/support/compare.js	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/support/compare.js	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,39 @@
+function sameDate(d1, d2) {
+  return (d1 instanceof Date && d2 instanceof Date && d1.valueOf() == d2.valueOf());
+}
+
+function sameRE(r1, r2) {
+  return (r1 instanceof RegExp && r2 instanceof RegExp && r1.toString() == r2.toString());
+}
+
+function assert_array_equals_(observed, expected, msg) {
+  if (observed.length == expected.length) {
+    for (var i = 0; i < observed.length; i++) {
+      if (observed[i] instanceof Date) {
+        observed[i] = sameDate(observed[i], expected[i]);
+        expected[i] = true;
+      } else if (observed[i] instanceof RegExp) {
+        observed[i] = sameRE(observed[i], expected[i]);
+        expected[i] = true;
+      }
+    }
+  }
+
+  assert_array_equals(observed, expected, msg);
+}
+
+function assert_object_equals_(observed, expected, msg) {
+  for (var p in observed) {
+    if (observed[p] instanceof Date) {
+      observed[p] = sameDate(observed[p], expected[p]);
+      expected[p] = true;
+    } else if (observed[p] instanceof RegExp) {
+      observed[p] = sameRE(observed[p], expected[p]);
+      expected[p] = true;
+    } else if (observed[p] instanceof Array || String(observed[p]) === '[object Object]') {
+      observed[p] = String(observed[p]) === String(expected[p]);
+      expected[p] = true;
+    }
+    assert_equals(observed[p], expected[p], msg);
+  }
+}

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/support/w3c-import.log (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/support/w3c-import.log	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/support/w3c-import.log	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,18 @@
+The tests in this directory were imported from the W3C repository.
+Do NOT modify these tests directly in WebKit.
+Instead, create a pull request on the WPT github:
+	https://github.com/web-platform-tests/wpt
+
+Then run the Tools/Scripts/import-w3c-tests in WebKit to reimport
+
+Do NOT modify or remove this file.
+
+------------------------------------------------------------------------
+Properties requiring vendor prefixes:
+None
+Property values requiring vendor prefixes:
+None
+------------------------------------------------------------------------
+List of files:
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/support/ChildWindowPostMessage.htm
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/support/compare.js

Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/w3c-import.log (253450 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/w3c-import.log	2019-12-12 23:53:40 UTC (rev 253450)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/w3c-import.log	2019-12-13 00:02:51 UTC (rev 253451)
@@ -21,6 +21,10 @@
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_event_properties.htm
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_ports_readonly_array.htm
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_target_source.htm
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_transfer_xsite_incoming_messages.window.js
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_entangled.any.js
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_incoming_messages.any.js
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/Channel_postMessage_with_transfer_outgoing_messages.any.js
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/META.yml
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/MessageEvent-trusted-worker.js
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/MessageEvent-trusted.html
@@ -43,6 +47,7 @@
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_Function.htm
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_MessagePorts_sorigin.htm
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_MessagePorts_xorigin.sub.htm
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_MessagePorts_xsite.sub.window.js
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_arrays.sub.htm
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_asterisk_xorigin.sub.htm
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_dup_transfer_objects.htm
@@ -52,3 +57,5 @@
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_origin_mismatch_xorigin.sub.htm
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_solidus_sorigin.htm
 /LayoutTests/imported/w3c/web-platform-tests/webmessaging/postMessage_solidus_xorigin.sub.htm
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/worker_postMessage_user_activation.js
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/worker_postMessage_user_activation.tentative.html

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/broken-origin-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/broken-origin-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/broken-origin-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+PASS resolving broken url 
+

Copied: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/broken-origin.html (from rev 253450, trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/008.html) (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/broken-origin.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/broken-origin.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,12 @@
+<!doctype html>
+<title>resolving broken url</title>
+<script src=""
+<script src=""
+<div id="log"></div>
+<script>
+test(function() {
+  assert_throws('SYNTAX_ERR', function() {
+    postMessage('', {targetOrigin: 'http://foo bar'});
+  }, 'should have failed to resolve');
+});
+</script>

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/host-specific-origin-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/host-specific-origin-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/host-specific-origin-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+FAIL resolving url with stuff in host-specific The string did not match the expected pattern.
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/host-specific-origin.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/host-specific-origin.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/host-specific-origin.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,14 @@
+<!doctype html>
+<title>resolving url with stuff in host-specific</title>
+<script src=""
+<script src=""
+<div id="log"></div>
+<script>
+async_test(function() {
+  postMessage('', {targetOrigin: location.protocol + '//' + location.host + '//'});
+  _onmessage_ = this.step_func(function(e) {
+    assert_equals(e.origin, location.protocol + '//' + location.host);
+    this.done();
+  });
+});
+</script>

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/message-channel-transferable-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/message-channel-transferable-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/message-channel-transferable-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+FAIL MessageChannel's ports as MessagePort objects The string did not match the expected pattern.
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/message-channel-transferable.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/message-channel-transferable.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/message-channel-transferable.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,15 @@
+<!doctype html>
+<title>message channel as ports</title>
+<script src=""
+<script src=""
+<div id=log></div>
+<script>
+async_test(function(t) {
+  var channel = new MessageChannel();
+  postMessage('', {targetOrigin: '*', transfer: [channel.port1, channel.port2]});
+  _onmessage_ = t.step_func(function(e) {
+    assert_equals(e.ports.length, 2);
+    t.done();
+  });
+}, "MessageChannel's ports as MessagePort objects");
+</script>

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/no-target-origin-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/no-target-origin-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/no-target-origin-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+FAIL no targetOrigin The string did not match the expected pattern.
+

Copied: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/no-target-origin.html (from rev 253450, trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/008.html) (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/no-target-origin.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/no-target-origin.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,14 @@
+<!doctype html>
+<title>no targetOrigin</title>
+<script src=""
+<script src=""
+<div id="log"></div>
+<script>
+async_test(function() {
+  postMessage('', {});
+  _onmessage_ = this.step_func(function(e) {
+    assert_equals(e.data, '');
+    this.done();
+  });
+});
+</script>

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/null-transfer-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/null-transfer-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/null-transfer-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+FAIL null transfer assert_throws: function "() => postMessage('', {transfer: null})" threw object "SyntaxError: The string did not match the expected pattern." ("SyntaxError") expected object "TypeError" ("TypeError")
+

Copied: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/null-transfer.html (from rev 253450, trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/008.html) (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/null-transfer.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/null-transfer.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,10 @@
+<!doctype html>
+<title>null transfer</title>
+<script src=""
+<script src=""
+<div id=log></div>
+<script>
+test(function(t) {
+  assert_throws(new TypeError, () => postMessage('', {transfer: null}));
+});
+</script>

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/one-arg-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/one-arg-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/one-arg-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+FAIL just one argument Not enough arguments
+

Copied: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/one-arg.html (from rev 253450, trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/008.html) (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/one-arg.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/one-arg.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,14 @@
+<!doctype html>
+<title>just one argument</title>
+<script src=""
+<script src=""
+<div id="log"></div>
+<script>
+test(function() {
+  postMessage('');
+  _onmessage_ = this.step_func(function(e) {
+    assert_equals(e.data, '');
+    this.done();
+  });
+});
+</script>

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/slash-origin-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/slash-origin-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/slash-origin-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+FAIL special value '/' The string did not match the expected pattern.
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/slash-origin.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/slash-origin.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/slash-origin.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,14 @@
+<!doctype html>
+<title>special value '/'</title>
+<script src=""
+<script src=""
+<div id="log"></div>
+<script>
+async_test(function() {
+  postMessage('', {targetOrigin: '/'});
+  _onmessage_ = this.step_func(function(e) {
+    assert_equals(e.data, '');
+    this.done();
+  });
+});
+</script>

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/undefined-transferable-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/undefined-transferable-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/undefined-transferable-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+FAIL undefined as transferable The string did not match the expected pattern.
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/undefined-transferable.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/undefined-transferable.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/undefined-transferable.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,14 @@
+<!doctype html>
+<title>undefined as transferable</title>
+<script src=""
+<script src=""
+<div id=log></div>
+<script>
+async_test(function() {
+  postMessage('', {transfer: undefined});
+  _onmessage_ = this.step_func(function(e) {
+    assert_array_equals(e.ports, []);
+    this.done();
+  });
+});
+</script>

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/unknown-parameter-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/unknown-parameter-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/unknown-parameter-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+FAIL unknown parameter The string did not match the expected pattern.
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/unknown-parameter.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/unknown-parameter.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/unknown-parameter.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,14 @@
+<!doctype html>
+<title>unknown parameter</title>
+<script src=""
+<script src=""
+<div id="log"></div>
+<script>
+async_test(function() {
+  postMessage('', {someBogusParameterOnThisDictionary: 'food'});
+  _onmessage_ = this.step_func(function(e) {
+    assert_equals(e.data, '');
+    this.done();
+  });
+});
+</script>

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/w3c-import.log (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/w3c-import.log	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/w3c-import.log	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,25 @@
+The tests in this directory were imported from the W3C repository.
+Do NOT modify these tests directly in WebKit.
+Instead, create a pull request on the WPT github:
+	https://github.com/web-platform-tests/wpt
+
+Then run the Tools/Scripts/import-w3c-tests in WebKit to reimport
+
+Do NOT modify or remove this file.
+
+------------------------------------------------------------------------
+Properties requiring vendor prefixes:
+None
+Property values requiring vendor prefixes:
+None
+------------------------------------------------------------------------
+List of files:
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/broken-origin.html
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/host-specific-origin.html
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/message-channel-transferable.html
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/no-target-origin.html
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/null-transfer.html
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/one-arg.html
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/slash-origin.html
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/undefined-transferable.html
+/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-options/unknown-parameter.html

Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-ports/010-expected.txt (253450 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-ports/010-expected.txt	2019-12-12 23:53:40 UTC (rev 253450)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-ports/010-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -7,11 +7,11 @@
 PASS NaN 
 PASS Infinity 
 PASS string 
-FAIL date Can't find variable: sameDate
+PASS date 
 PASS regex 
 PASS self 
-FAIL array Can't find variable: assert_array_equals_
-FAIL object Can't find variable: assert_object_equals_
+PASS array 
+PASS object 
 PASS error 
 PASS unreached 
 

Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-ports/020.html (253450 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-ports/020.html	2019-12-12 23:53:40 UTC (rev 253450)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-ports/020.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -5,6 +5,8 @@
 <iframe src=""
 <div id="log"></div>
 <script>
+setup({ single_test: true });
+
 var iframe = document.createElement('iframe');
 var url_prefix = location.href.replace('://', '://www1.').replace(/\/with(out)?-ports\/[^\/]+$/, '');
 var url = "" + '/without-ports/020-1.html';

Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-ports/021.html (253450 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-ports/021.html	2019-12-12 23:53:40 UTC (rev 253450)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/with-ports/021.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -5,6 +5,8 @@
 <iframe src=""
 <div id="log"></div>
 <script>
+setup({ single_test: true });
+
 var iframe = document.createElement('iframe');
 var url_prefix = location.href.replace('://', '://www1.').replace(/\/with(out)?-ports\/[^\/]+$/, '');
 var url = "" + '/without-ports/020-1.html';

Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/008-expected.txt (253450 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/008-expected.txt	2019-12-12 23:53:40 UTC (rev 253450)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/008-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -1,3 +1,3 @@
 
-PASS just one argument 
+FAIL just one argument Not enough arguments
 

Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/008.html (253450 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/008.html	2019-12-12 23:53:40 UTC (rev 253450)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/008.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -5,8 +5,7 @@
 <div id="log"></div>
 <script>
 test(function() {
-  assert_throws(new TypeError(), function() {
-    postMessage('');
-  });
-});
-</script>
+  postMessage('');
+  this.done();
+ });
+ </script>

Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/010-expected.txt (253450 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/010-expected.txt	2019-12-12 23:53:40 UTC (rev 253450)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/010-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -7,11 +7,11 @@
 PASS NaN 
 PASS Infinity 
 PASS string 
-FAIL date Can't find variable: sameDate
+PASS date 
 PASS regex 
 PASS self 
-FAIL array Can't find variable: assert_array_equals_
-FAIL object Can't find variable: assert_object_equals_
+PASS array 
+PASS object 
 PASS error 
 PASS unreached 
 

Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/020.html (253450 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/020.html	2019-12-12 23:53:40 UTC (rev 253450)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/020.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -5,6 +5,8 @@
 <iframe src=""
 <div id="log"></div>
 <script>
+setup({ single_test: true });
+
 var iframe = document.createElement('iframe');
 var url_prefix = location.href.replace('://', '://www1.').replace(/\/with(out)?-ports\/[^\/]+$/, '');
 var url = "" + '/without-ports/020-1.html';

Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/021.html (253450 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/021.html	2019-12-12 23:53:40 UTC (rev 253450)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/without-ports/021.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -5,6 +5,8 @@
 <iframe src=""
 <div id="log"></div>
 <script>
+setup({ single_test: true });
+
 var iframe = document.createElement('iframe');
 var url_prefix = location.href.replace('://', '://www1.').replace(/\/with(out)?-ports\/[^\/]+$/, '');
 var url = "" + '/without-ports/020-1.html';

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/worker_postMessage_user_activation.js (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/worker_postMessage_user_activation.js	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/worker_postMessage_user_activation.js	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+"use strict";
+
+_onmessage_ = e => postMessage(e.userActivation !== null);

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/worker_postMessage_user_activation.tentative-expected.txt (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/worker_postMessage_user_activation.tentative-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/worker_postMessage_user_activation.tentative-expected.txt	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,3 @@
+
+FAIL Post Message from a worker promise_test: Unhandled rejection with value: object "TypeError: Type error"
+

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/worker_postMessage_user_activation.tentative.html (0 => 253451)


--- trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/worker_postMessage_user_activation.tentative.html	                        (rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webmessaging/worker_postMessage_user_activation.tentative.html	2019-12-13 00:02:51 UTC (rev 253451)
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<title>postMessage with user activtion to a worker</title>
+<script src=""
+<script src=""
+
+<script>
+"use strict";
+
+promise_test(async t => {
+  var worker = new Worker("worker_postMessage_user_activation.js");
+  let workerReply = () => new Promise((resolve, reject) => {
+    worker.addEventListener('message', e => resolve(e.data), {once: true});
+  });
+  worker.postMessage(null, {includeUserActivation: true});
+  assert_equals(await workerReply(), true);
+  worker.postMessage(null, {includeUserActivation: false});
+  assert_equals(await workerReply(), false);
+}, "Post Message from a worker");
+</script>
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to