Bug 1498102 - Add a rejection handler to another promise chain in the test which was forgotten in the previous debugging patch
authorEhsan Akhgari <ehsan@mozilla.com>
Mon, 15 Oct 2018 10:06:53 -0400
changeset 497072 78add290fb096999f15edf658aa4026c197ed366
parent 497025 4f99223da02146842694203124351f21b96dec5a
child 497073 c0b3c3c948fde682b37efa237235248aeb1f7ec2
push id9996
push userarchaeopteryx@coole-files.de
push dateThu, 18 Oct 2018 18:37:15 +0000
treeherdermozilla-beta@8efe26839243 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1498102
milestone64.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 1498102 - Add a rejection handler to another promise chain in the test which was forgotten in the previous debugging patch
toolkit/components/antitracking/test/browser/browser_blockingServiceWorkers.js
--- a/toolkit/components/antitracking/test/browser/browser_blockingServiceWorkers.js
+++ b/toolkit/components/antitracking/test/browser/browser_blockingServiceWorkers.js
@@ -1,15 +1,16 @@
 requestLongerTimeout(2);
 
 AntiTracking.runTest("ServiceWorkers",
   async _ => {
     await navigator.serviceWorker.register("empty.js").then(
       _ => { ok(false, "ServiceWorker cannot be used!"); },
-      _ => { ok(true, "ServiceWorker cannot be used!"); });
+      _ => { ok(true, "ServiceWorker cannot be used!"); }).
+      catch(e => ok(false, "Promise rejected: " + e));
   },
   null,
   async _ => {
     await new Promise(resolve => {
       Services.clearData.deleteData(Ci.nsIClearDataService.CLEAR_ALL, value => resolve());
     });
   },
   [["dom.serviceWorkers.exemptFromPerDomainMax", true],