Bug 1427726 - remove postMessage tests for jars, r=bz
authorGijs Kruitbosch <gijskruitbosch@gmail.com>
Mon, 09 Apr 2018 10:09:58 +0100
changeset 412748 bfff5b3739f90427518ba2f6f5af3d9f75e1660c
parent 412747 25b2e11c93b418defdef44aed8fd7d375c6748b3
child 412749 a9185d7a30d832b0f93919f8522bd465e96a9b45
push id62493
push usergijskruitbosch@gmail.com
push dateWed, 11 Apr 2018 11:27:43 +0000
treeherderautoland@964dbe5e2afe [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbz
bugs1427726
milestone61.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1427726 - remove postMessage tests for jars, r=bz postMessage doesn't really have different origins for file: URIs; to send to them you need "*", and `location.origin` is null. So testing jar:file separately doesn't seem to make much sense, so let's just remove the test now that jar: will only really be usable with a local/file inner URI. MozReview-Commit-ID: 7vvlrugi3xv
dom/tests/mochitest/whatwg/mochitest.ini
dom/tests/mochitest/whatwg/postMessage.jar
dom/tests/mochitest/whatwg/postMessage.jar^headers^
dom/tests/mochitest/whatwg/test_postMessage_jar.html
--- a/dom/tests/mochitest/whatwg/mochitest.ini
+++ b/dom/tests/mochitest/whatwg/mochitest.ini
@@ -1,18 +1,16 @@
 [DEFAULT]
 support-files =
   browserFu.js
   postMessage_chrome_helper.html
   postMessage_closed_helper.html
   postMessage_hash.html
   postMessage_helper.html
   postMessage_idn_helper.html
-  postMessage.jar
-  postMessage.jar^headers^
   postMessage_joined_helper2.html
   postMessage_joined_helper.html
   postMessage_onOther.html
   postMessage_origin_helper.xhtml
   postMessage_override_helper.html
   postMessage_structured_clone_helper.html
   postMessage_structured_clone_helper.js
   postMessage_throw_helper.html
@@ -24,17 +22,16 @@ support-files =
 [test_MessageEvent_dispatchToOther.html]
 [test_MessageEvent.html]
 [test_postMessage_basehref.html]
 [test_postMessage_closed.html]
 skip-if = toolkit == 'android' #bug 894914 - wrong data - got FAIL, expected message
 [test_postMessage_hash.html]
 [test_postMessage.html]
 [test_postMessage_idn.xhtml]
-[test_postMessage_jar.html]
 [test_postMessage_joined.html]
 [test_postMessage_onOther.html]
 [test_postMessage_origin.xhtml]
 [test_postMessage_override.html]
 [test_postMessage_special.xhtml]
 [test_postMessage_structured_clone.html]
 [test_postMessage_throw.html]
 [test_postMessage_transfer.html]
deleted file mode 100644
index d4ee4abc3d19283fd89574bc21bd8a9b7ba571c4..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
GIT binary patch
literal 0
Hc$@<O00001
deleted file mode 100644
--- a/dom/tests/mochitest/whatwg/postMessage.jar^headers^
+++ /dev/null
@@ -1,1 +0,0 @@
-Content-Type: application/java-archive
deleted file mode 100644
--- a/dom/tests/mochitest/whatwg/test_postMessage_jar.html
+++ /dev/null
@@ -1,52 +0,0 @@
-<!DOCTYPE html>
-<html>
-<!--
-https://bugzilla.mozilla.org/show_bug.cgi?id=430251
--->
-<head>
-  <title>postMessage's interaction with pages at jar: URIs</title>
-  <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>        
-  <script type="text/javascript" src="browserFu.js"></script>
-  <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
-  <base href="http://mochi.test:8888/" />
-</head>
-<body>
-<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=430251">Mozilla Bug 430251</a>
-<p id="display"></p>
-<div id="content" style="display: none"></div>
-
-<pre id="test">
-<script class="testbody" type="application/javascript">
-/** Test for Bug 430251 **/
-
-SimpleTest.waitForExplicitFinish();
-
-function receiveMessage(evt)
-{
-  is(evt.origin, "http://mochi.test:8888", "wrong sender");
-  ok(evt.source === window.frames.kid, "wrong source");
-
-  is(evt.data, "finish-test", "wrong data");
-  is(evt.lastEventId, "", "wrong lastEventId");
-
-  SimpleTest.finish();
-}
-
-window.addEventListener("message", receiveMessage);
-
-addLoadEvent(function() {
-  SpecialPowers.pushPrefEnv({"set": [["network.jar.block-remote-files", false]]}, function() {
-    var iframe = document.createElement('iframe');
-    iframe.setAttribute('src', 'jar:http://mochi.test:8888/tests/dom/tests/mochitest/whatwg/postMessage.jar!/postMessage_jar.html');
-    iframe.setAttribute('name', 'kid');
-    document.getElementById("content").appendChild(iframe);
-
-    iframe.onload = function() {
-      window.frames.kid.postMessage("start-test", "http://mochi.test:8888");
-    }
-  });
-});
-</script>
-</pre>
-</body>
-</html>