Bug 1640879 - Fix COEP data.http.html test r=annevk
authorValentin Gosu <valentin.gosu@gmail.com>
Tue, 26 May 2020 13:52:55 +0000
changeset 532162 e611adfdfed4c6e6f17e49f25526d62e4bdf9588
parent 532161 9c5404219f8672a1ea9f533357b7295c85a06d6c
child 532163 0483bc7c9ff3c411c551bb15bf758bbe41d027f4
push id37451
push usercsabou@mozilla.com
push dateTue, 26 May 2020 21:37:52 +0000
treeherdermozilla-central@e803948bb3cd [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersannevk
bugs1640879
milestone78.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 1640879 - Fix COEP data.http.html test r=annevk Differential Revision: https://phabricator.services.mozilla.com/D76839
testing/web-platform/meta/html/cross-origin-embedder-policy/data.https.html.ini
testing/web-platform/tests/html/cross-origin-embedder-policy/data.https.html
deleted file mode 100644
--- a/testing/web-platform/meta/html/cross-origin-embedder-policy/data.https.html.ini
+++ /dev/null
@@ -1,5 +0,0 @@
-[data.https.html]
-  expected: TIMEOUT
-  [Cross-Origin-Embedder-Policy and data: URLs]
-    expected: TIMEOUT
-
--- a/testing/web-platform/tests/html/cross-origin-embedder-policy/data.https.html
+++ b/testing/web-platform/tests/html/cross-origin-embedder-policy/data.https.html
@@ -9,12 +9,12 @@ async_test(t => {
   window.addEventListener("message", t.step_func_done(({ data }) => {
     assert_equals(data.id, "");
     assert_equals(data.origin, "null");
     assert_false(data.sameOriginNoCORPSuccess); // This is effectively a no-op for this test
     assert_true(data.crossOriginNoCORPFailure, "Cross-origin without CORP did not fail");
   }));
   const frame = document.createElement("iframe");
   t.add_cleanup(() => frame.remove());
-  frame.src = `data:text/html,<script>${createScript("null", window.origin)}<\/script>`;
+  frame.src = `data:text/html,<script>${encodeURIComponent(createScript("null", window.origin))}<\/script>`;
   document.body.append(frame);
 }, "Cross-Origin-Embedder-Policy and data: URLs");
 </script>