Bug 1499900 - Fix the test to use http://nonexistent.web-platform.test/ r=jgraham
authorWes Kocher <wkocher@mozilla.com>
Wed, 24 Oct 2018 21:43:06 +0000
changeset 442863 dae5b4b90a4209aea03c26937ffb3a71ce0767c8
parent 442862 03132dcf8ae5bf49bf58008bad7f97f0b9d3e4d4
child 442864 09f5387e2002f4efa33043895decc4c05dcf5d18
push id71686
push userjames@hoppipolla.co.uk
push dateWed, 24 Oct 2018 21:45:21 +0000
treeherderautoland@dae5b4b90a42 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjgraham
bugs1499900
milestone65.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 1499900 - Fix the test to use http://nonexistent.web-platform.test/ r=jgraham Differential Revision: https://phabricator.services.mozilla.com/D9263
testing/web-platform/meta/beacon/beacon-error.sub.window.js.ini
testing/web-platform/meta/beacon/beacon-error.window.js.ini
testing/web-platform/tests/beacon/beacon-error.sub.window.js
testing/web-platform/tests/beacon/beacon-error.window.js
rename from testing/web-platform/meta/beacon/beacon-error.window.js.ini
rename to testing/web-platform/meta/beacon/beacon-error.sub.window.js.ini
--- a/testing/web-platform/meta/beacon/beacon-error.window.js.ini
+++ b/testing/web-platform/meta/beacon/beacon-error.sub.window.js.ini
@@ -1,9 +1,9 @@
-[beacon-error.window.html]
+[beacon-error.sub.window.html]
   [Verify calling 'navigator.sendBeacon()' with a large payload returns 'false'.]
     expected: FAIL
 
   [Verify calling 'navigator.sendBeacon()' with a small payload fails while Quota is completely utilized.]
     expected: FAIL
 
   [Verify the behavior after the quota is exhausted.]
     expected: FAIL
rename from testing/web-platform/tests/beacon/beacon-error.window.js
rename to testing/web-platform/tests/beacon/beacon-error.sub.window.js
--- a/testing/web-platform/tests/beacon/beacon-error.window.js
+++ b/testing/web-platform/tests/beacon/beacon-error.sub.window.js
@@ -2,17 +2,17 @@
 // META: script=beacon-common.sub.js
 
 "use strict";
 
 test(function() {
     // Payload that should cause sendBeacon to return false because it exceeds the maximum payload size.
     var exceedPayload = Array(maxPayloadSize + 1).fill('z').join("");
 
-    var success = navigator.sendBeacon("http://doesnotmatter", exceedPayload);
+    var success = navigator.sendBeacon("http://{{hosts[][nonexistent]}}", exceedPayload);
     assert_false(success, "calling 'navigator.sendBeacon()' with payload size exceeding the maximum size must fail");
 }, "Verify calling 'navigator.sendBeacon()' with a large payload returns 'false'.");
 
 test(function() {
     var invalidUrl = "http://invalid:url";
     assert_throws(new TypeError(), function() { navigator.sendBeacon(invalidUrl, smallPayload); },
         `calling 'navigator.sendBeacon()' with an invalid URL '${invalidUrl}' must throw a TypeError`);
 }, "Verify calling 'navigator.sendBeacon()' with an invalid URL throws an exception.");