Bug 1589334 - Enable ESLint for all of devtools/shared/ (automatic changes). r=Standard8,jdescottes
authorMarco Vega <marco@proweb.co>
Tue, 03 Dec 2019 10:11:13 +0000
changeset 505045 52f5558248143b436fecc2e3755c2757ddbe6a4b
parent 505044 de01e89b8da048e07de8fc47434ea0c4829337b2
child 505046 f37f7892f77f58a983b82a15f6babc0db8afbcb1
push id102117
push usermbanner@mozilla.com
push dateTue, 03 Dec 2019 10:12:10 +0000
treeherderautoland@f37f7892f77f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersStandard8, jdescottes
bugs1589334
milestone73.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 1589334 - Enable ESLint for all of devtools/shared/ (automatic changes). r=Standard8,jdescottes # ignore-this-changeset Differential Revision: https://phabricator.services.mozilla.com/D51089
devtools/shared/qrcode/tests/mochitest/test_decode.html
devtools/shared/tests/mochitest/test_css-logic-getCssPath.html
devtools/shared/tests/mochitest/test_css-logic-getXPath.html
devtools/shared/webconsole/test/test_basics.html
devtools/shared/webconsole/test/test_bug819670_getter_throws.html
devtools/shared/webconsole/test/test_cached_messages.html
devtools/shared/webconsole/test/test_commands_other.html
devtools/shared/webconsole/test/test_console_group_styling.html
devtools/shared/webconsole/test/test_console_serviceworker.html
devtools/shared/webconsole/test/test_console_serviceworker_cached.html
devtools/shared/webconsole/test/test_console_worker.html
devtools/shared/webconsole/test/test_consoleapi.html
devtools/shared/webconsole/test/test_consoleapi_innerID.html
devtools/shared/webconsole/test/test_file_uri.html
devtools/shared/webconsole/test/test_jsterm.html
devtools/shared/webconsole/test/test_jsterm_autocomplete.html
devtools/shared/webconsole/test/test_jsterm_cd_iframe.html
devtools/shared/webconsole/test/test_jsterm_last_result.html
devtools/shared/webconsole/test/test_jsterm_queryselector.html
devtools/shared/webconsole/test/test_network_get.html
devtools/shared/webconsole/test/test_network_post.html
devtools/shared/webconsole/test/test_network_security-hpkp.html
devtools/shared/webconsole/test/test_network_security-hsts.html
devtools/shared/webconsole/test/test_nsiconsolemessage.html
devtools/shared/webconsole/test/test_object_actor.html
devtools/shared/webconsole/test/test_object_actor_native_getters.html
devtools/shared/webconsole/test/test_object_actor_native_getters_lenient_this.html
devtools/shared/webconsole/test/test_page_errors.html
devtools/shared/webconsole/test/test_throw.html
--- a/devtools/shared/qrcode/tests/mochitest/test_decode.html
+++ b/devtools/shared/qrcode/tests/mochitest/test_decode.html
@@ -25,26 +25,26 @@ window.onload = function() {
     "dkhZUK1umE6jZXJ2ZJaujZaRqH4bpb2uZrJxvIt4Ebe9qoYYrJOsw8apz2bCut" +
     "m9kqDcw52uuImyr5Oh1KXH1jrn2anuunywtODU/o2c6teceW39ZcLFg/fNMo1b" +
     "t3jVw2dwTPwJq1KYG3gAklCgu37yGxeScYKyiCc+7DR34hPVQiuQ7UhJMagyEb" +
     "lymmzJk0a9q8iTOnzp0NCgAAOw==";
 
   (async function () {
     let result = await QR.decodeFromURI(testImage);
     is(result, "HELLO", "Decoded data URI result matches");
-    let canvas = await drawToCanvas(testImage);
+    const canvas = await drawToCanvas(testImage);
     result = QR.decodeFromCanvas(canvas);
     is(result, "HELLO", "Decoded canvas result matches");
   })().then(SimpleTest.finish, ok.bind(null, false));
 
   function drawToCanvas(src) {
     return new Promise(resolve => {
-      let canvas = document.createElement("canvas");
-      let context = canvas.getContext("2d");
-      let image = new Image();
+      const canvas = document.createElement("canvas");
+      const context = canvas.getContext("2d");
+      const image = new Image();
 
       image.onload = () => {
         canvas.width = image.width;
         canvas.height = image.height;
         context.drawImage(image, 0, 0);
         resolve(canvas);
       };
       image.src = src;
--- a/devtools/shared/tests/mochitest/test_css-logic-getCssPath.html
+++ b/devtools/shared/tests/mochitest/test_css-logic-getCssPath.html
@@ -6,17 +6,17 @@ https://bugzilla.mozilla.org/show_bug.cg
 <head>
   <meta charset="utf-8">
   <title>Test for Bug 1323700</title>
 
   <script src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"></script>
   <link rel="stylesheet" type="text/css" href="chrome://mochikit/content/tests/SimpleTest/test.css">
   <script type="application/javascript">
 
-let { require } = ChromeUtils.import("resource://devtools/shared/Loader.jsm");
+const { require } = ChromeUtils.import("resource://devtools/shared/Loader.jsm");
 const CssLogic = require("devtools/shared/inspector/css-logic");
 
 var _tests = [];
 function addTest(test) {
   _tests.push(test);
 }
 
 function runNextTest() {
@@ -43,52 +43,52 @@ addTest(function getCssPathForUnattached
 
   var unattachedBody = document.createElement("body");
   is(CssLogic.getCssPath(unattachedBody), "", "Unattached body returns empty string");
 
   runNextTest();
 });
 
 addTest(function cssPathHasOneStepForEachAncestor() {
-  for (let el of [...document.querySelectorAll('*')]) {
-    let splitPath = CssLogic.getCssPath(el).split(" ");
+  for (const el of [...document.querySelectorAll('*')]) {
+    const splitPath = CssLogic.getCssPath(el).split(" ");
 
     let expectedNbOfParts = 0;
     var parent = el.parentNode;
     while (parent) {
       expectedNbOfParts ++;
       parent = parent.parentNode;
     }
 
     is(splitPath.length, expectedNbOfParts, "There are enough parts in the full path");
   }
 
   runNextTest();
 });
 
 addTest(function getCssPath() {
-  let data = [{
+  const data = [{
     selector: "#id",
     path: "html body div div div.class div#id"
   }, {
     selector: "html",
     path: "html"
   }, {
     selector: "body",
     path: "html body"
   }, {
     selector: ".c1.c2.c3",
     path: "html body span.c1.c2.c3"
   }, {
     selector: "#i",
     path: "html body span#i.c1.c2"
   }];
 
-  for (let {selector, path} of data) {
-    let node = document.querySelector(selector);
+  for (const {selector, path} of data) {
+    const node = document.querySelector(selector);
     is (CssLogic.getCssPath(node), path, `Full css path is correct for ${selector}`);
   }
 
   runNextTest();
 });
   </script>
 </head>
 <body>
--- a/devtools/shared/tests/mochitest/test_css-logic-getXPath.html
+++ b/devtools/shared/tests/mochitest/test_css-logic-getXPath.html
@@ -29,32 +29,32 @@ function runNextTest() {
 }
 
 window.onload = function () {
   SimpleTest.waitForExplicitFinish();
   runNextTest();
 };
 
 addTest(function getXPathForUnattachedElement() {
-  let unattached = document.createElement("div");
+  const unattached = document.createElement("div");
   unattached.id = "unattached";
   is(CssLogic.getXPath(unattached), "", "Unattached node returns empty string");
 
-  let unattachedChild = document.createElement("div");
+  const unattachedChild = document.createElement("div");
   unattached.appendChild(unattachedChild);
   is(CssLogic.getXPath(unattachedChild), "", "Unattached child returns empty string");
 
-  let unattachedBody = document.createElement("body");
+  const unattachedBody = document.createElement("body");
   is(CssLogic.getXPath(unattachedBody), "", "Unattached body returns empty string");
 
   runNextTest();
 });
 
 addTest(function getXPath() {
-  let data = [{
+  const data = [{
     // Target elements that have an ID get a short XPath.
     selector: "#i-have-an-id",
     path: "//*[@id=\"i-have-an-id\"]"
   }, {
     selector: "html",
     path: "/html"
   }, {
     selector: "body",
@@ -63,18 +63,18 @@ addTest(function getXPath() {
     selector: "body > div:nth-child(2) > div > div:nth-child(4)",
     path: "/html/body/div[2]/div/div[4]"
   }, {
     // XPath should support namespace.
     selector: "namespace\\:body",
     path: "/html/body/namespace:test/namespace:body"
   }];
 
-  for (let {selector, path} of data) {
-    let node = document.querySelector(selector);
+  for (const {selector, path} of data) {
+    const node = document.querySelector(selector);
     is(CssLogic.getXPath(node), path, `Full css path is correct for ${selector}`);
   }
 
   runNextTest();
 });
   </script>
 </head>
 <body>
--- a/devtools/shared/webconsole/test/test_basics.html
+++ b/devtools/shared/webconsole/test/test_basics.html
@@ -32,17 +32,17 @@ function onStartPageError(aState, aRespo
     top.console = { lolz: "foo" };
     attachConsoleToTab(["PageError", "ConsoleAPI", "foo"],
                   onStartPageErrorAndConsoleAPI);
   });
 }
 
 function onStartPageErrorAndConsoleAPI(aState, aResponse)
 {
-  let startedListeners = aResponse.startedListeners;
+  const startedListeners = aResponse.startedListeners;
   is(startedListeners.length, 2, "startedListeners.length");
   isnot(startedListeners.indexOf("PageError"), -1, "startedListeners: PageError");
   isnot(startedListeners.indexOf("ConsoleAPI"), -1,
         "startedListeners: ConsoleAPI");
   is(startedListeners.indexOf("foo"), -1, "startedListeners: no foo");
   ok(!aResponse.nativeConsoleAPI, "!nativeConsoleAPI");
 
   top.console = top.console_;
--- a/devtools/shared/webconsole/test/test_bug819670_getter_throws.html
+++ b/devtools/shared/webconsole/test/test_bug819670_getter_throws.html
@@ -35,27 +35,27 @@ function onEvaluate(aState, aResponse)
       actor: /[a-z]/,
     },
   });
 
   ok(!aResponse.exception, "no eval exception");
   ok(!aResponse.helperResult, "no helper result");
 
   onInspect = onInspect.bind(null, aState);
-  let client = new ObjectFront(aState.dbgClient, aResponse.result);
+  const client = new ObjectFront(aState.dbgClient, aResponse.result);
   client.getPrototypeAndProperties().then(onInspect);
 }
 
 function onInspect(aState, aResponse)
 {
   ok(!aResponse.error, "no response error");
 
-  let expectedProps =  Object.getOwnPropertyNames(document.__proto__);
+  const expectedProps =  Object.getOwnPropertyNames(document.__proto__);
 
-  let props = aResponse.ownProperties;
+  const props = aResponse.ownProperties;
   ok(props, "response properties available");
 
   if (props) {
     isDeeply(Object.keys(props), expectedProps, "Same own properties.");
   }
 
   closeDebugger(aState, function() {
     SimpleTest.finish();
--- a/devtools/shared/webconsole/test/test_cached_messages.html
+++ b/devtools/shared/webconsole/test/test_cached_messages.html
@@ -101,35 +101,35 @@ var {ConsoleServiceListener} =
   require("devtools/server/actors/webconsole/listeners/console-service");
 var {ConsoleAPIListener} =
   require("devtools/server/actors/webconsole/listeners/console-api");
 
 let consoleAPIListener, consoleServiceListener;
 let consoleAPICalls = 0;
 let pageErrors = 0;
 
-let handlers = {
+const handlers = {
   onConsoleAPICall: function onConsoleAPICall(message) {
-    for (let msg of expectedConsoleCalls) {
+    for (const msg of expectedConsoleCalls) {
       if (msg.functionName == message.functionName &&
           msg.filename.test(message.filename)) {
         consoleAPICalls++;
         break;
       }
     }
     if (consoleAPICalls == expectedConsoleCalls.length) {
       checkConsoleAPICache();
     }
   },
 
   onConsoleServiceMessage: function onConsoleServiceMessage(message) {
     if (!(message instanceof Ci.nsIScriptError)) {
       return;
     }
-    for (let msg of expectedPageErrors) {
+    for (const msg of expectedPageErrors) {
       if (msg.category == message.category &&
           msg.errorMessage.test(message.errorMessage)) {
         pageErrors++;
         break;
       }
     }
     if (pageErrors == expectedPageErrors.length) {
       testPageErrors();
@@ -153,24 +153,24 @@ function checkConsoleAPICache() {
 }
 
 function onAttach1(state, response) {
   state.webConsoleFront.getCachedMessages(["ConsoleAPI"])
     .then(onCachedConsoleAPI.bind(null, state));
 }
 
 function onCachedConsoleAPI(state, response) {
-  let msgs = response.messages;
+  const msgs = response.messages;
   info("cached console messages: " + msgs.length);
 
   ok(msgs.length >= expectedConsoleCalls.length,
      "number of cached console messages");
 
-  for (let msg of msgs) {
-    for (let expected of expectedConsoleCalls) {
+  for (const msg of msgs) {
+    for (const expected of expectedConsoleCalls) {
       if (expected.functionName == msg.functionName &&
           expected.filename.test(msg.filename)) {
         expectedConsoleCalls.splice(expectedConsoleCalls.indexOf(expected));
         checkConsoleAPICall(msg, expected);
         break;
       }
     }
   }
@@ -191,24 +191,24 @@ function testPageErrors() {
 }
 
 function onAttach2(state, response) {
   state.webConsoleFront.getCachedMessages(["PageError"])
     .then(onCachedPageErrors.bind(null, state));
 }
 
 function onCachedPageErrors(state, response) {
-  let msgs = response.messages;
+  const msgs = response.messages;
   info("cached page errors: " + msgs.length);
 
   ok(msgs.length >= expectedPageErrors.length,
      "number of cached page errors");
 
-  for (let msg of msgs) {
-    for (let expected of expectedPageErrors) {
+  for (const msg of msgs) {
+    for (const expected of expectedPageErrors) {
       if (expected.category == msg.category &&
           expected.errorMessage.test(msg.errorMessage)) {
         expectedPageErrors.splice(expectedPageErrors.indexOf(expected));
         checkObject(msg, expected);
         break;
       }
     }
   }
--- a/devtools/shared/webconsole/test/test_commands_other.html
+++ b/devtools/shared/webconsole/test/test_commands_other.html
@@ -19,41 +19,41 @@ let tests;
 
 function evaluateJS(input) {
   return gState.webConsoleFront.evaluateJSAsync(input);
 }
 
 function startTest() {
   info ("Content window opened, attaching console to it");
 
-  let systemPrincipal = Cc["@mozilla.org/systemprincipal;1"].createInstance(Ci.nsIPrincipal);
+  const systemPrincipal = Cc["@mozilla.org/systemprincipal;1"].createInstance(Ci.nsIPrincipal);
   ok (!gWin.document.nodePrincipal.equals(systemPrincipal),
       "The test document is not using the system principal");
 
   attachConsoleToTab([], state => {
     gState = state;
     runTests(tests, testEnd);
   });
 }
 
 tests = [
   async function keys() {
-    let response = await evaluateJS("keys({foo: 'bar'})");
+    const response = await evaluateJS("keys({foo: 'bar'})");
     checkObject(response, {
       result: {
         class: "Array",
         preview: {
           items: ["foo"]
         }
       }
     });
     nextTest();
   },
   async function values() {
-    let response = await evaluateJS("values({foo: 'bar'})");
+    const response = await evaluateJS("values({foo: 'bar'})");
     checkObject(response, {
       result: {
         class: "Array",
         preview: {
           items: ["bar"]
         }
       }
     });
@@ -65,17 +65,17 @@ function testEnd() {
   gWin.close();
   gWin = null;
   closeDebugger(gState, function() {
     gState = null;
     SimpleTest.finish();
   });
 }
 
-let load = async function () {
+const load = async function () {
   removeEventListener("load", load);
 
   await new Promise(resolve => {
     SpecialPowers.pushPrefEnv({"set": [
       ["security.data_uri.unique_opaque_origin", false],
     ]}, resolve);
   });
 
--- a/devtools/shared/webconsole/test/test_console_group_styling.html
+++ b/devtools/shared/webconsole/test/test_console_group_styling.html
@@ -34,82 +34,82 @@ window.onload = async function () {
   }
 
   await closeDebugger(state);
   SimpleTest.finish();
 };
 
 async function testSingleCustomStyleGroup(consoleFront) {
   info("Testing console.group with a custom style");
-  let packet = await consoleAPICall(
+  const packet = await consoleAPICall(
     consoleFront,
     () => top.console.group("%cfoobar", "color:red")
   );
 
   checkConsoleAPICall(packet.message, {
     arguments: ["foobar"],
     styles: ["color:red"]
   });
 }
 
 async function testSingleCustomStyleGroupCollapsed(consoleFront) {
   info("Testing console.groupCollapsed with a custom style");
-  let packet = await consoleAPICall(
+  const packet = await consoleAPICall(
     consoleFront,
     () => top.console.groupCollapsed("%cfoobaz", "color:blue")
   );
 
   checkConsoleAPICall(packet.message, {
     arguments: ["foobaz"],
     styles: ["color:blue"]
   });
 }
 
 async function testMultipleCustomStyleGroup(consoleFront) {
   info("Testing console.group with multiple custom styles");
-  let packet = await consoleAPICall(
+  const packet = await consoleAPICall(
     consoleFront,
     () => top.console.group("%cfoo%cbar", "color:red", "color:blue")
   );
 
   checkConsoleAPICall(packet.message, {
     arguments: ["foo", "bar"],
     styles: ["color:red", "color:blue"]
   });
 }
 
 async function testMultipleCustomStyleGroupCollapsed(consoleFront) {
   info("Testing console.groupCollapsed with multiple custom styles");
-  let packet = await consoleAPICall(
+  const packet = await consoleAPICall(
     consoleFront,
     () => top.console.group("%cfoo%cbaz", "color:red", "color:green")
   );
 
   checkConsoleAPICall(packet.message, {
     arguments: ["foo", "baz"],
     styles: ["color:red", "color:green"]
   });
 }
 
 async function testFormatterWithNoStyleGroup(consoleFront) {
   info("Testing console.group with one formatter but no style");
-  let packet = await consoleAPICall(
+  const packet = await consoleAPICall(
     consoleFront,
     () => top.console.group("%cfoobar")
   );
 
   checkConsoleAPICall(packet.message, {
     arguments: ["%cfoobar"],
     styles: []
   });
 }
 
 async function testFormatterWithNoStyleGroupCollapsed(consoleFront) {
   info("Testing console.groupCollapsed with one formatter but no style");
-  let packet = await consoleAPICall(
+  const packet = await consoleAPICall(
     consoleFront,
     () => top.console.groupCollapsed("%cfoobaz")
   );
 
   checkConsoleAPICall(packet.message, {
     arguments: ["%cfoobaz"],
     styles: []
   });
--- a/devtools/shared/webconsole/test/test_console_serviceworker.html
+++ b/devtools/shared/webconsole/test/test_console_serviceworker.html
@@ -12,17 +12,17 @@
 <p>Test for the Console API and Service Workers</p>
 
 <script class="testbody" type="text/javascript">
 SimpleTest.waitForExplicitFinish();
 
 // Utils functions
 function withFrame(url) {
   return new Promise(resolve => {
-    let iframe = document.createElement("iframe");
+    const iframe = document.createElement("iframe");
     iframe.onload = function () {
       resolve(iframe);
     };
     iframe.src = url;
     document.body.appendChild(iframe);
   });
 }
 
@@ -45,38 +45,38 @@ function forceReloadFrame(iframe) {
 }
 
 function messageServiceWorker(win, scope, message) {
   return win.navigator.serviceWorker.getRegistration(scope).then(swr => {
     return new Promise(resolve => {
       win.navigator.serviceWorker.onmessage = evt => {
         resolve();
       };
-      let sw = swr.active || swr.waiting || swr.installing;
+      const sw = swr.active || swr.waiting || swr.installing;
       sw.postMessage({ type: "PING", message: message });
     });
   });
 }
 
 function unregisterServiceWorker(win) {
   return win.navigator.serviceWorker.ready.then(swr => {
     return swr.unregister();
   });
 }
 
 // Test
-let BASE_URL = "https://example.com/chrome/devtools/shared/webconsole/test/";
-let SERVICE_WORKER_URL = BASE_URL + "helper_serviceworker.js";
-let SCOPE = BASE_URL + "foo/";
-let NONSCOPE_FRAME_URL = BASE_URL + "sandboxed_iframe.html";
-let SCOPE_FRAME_URL = SCOPE + "fake.html";
-let SCOPE_FRAME_URL2 = SCOPE + "whatsit.html";
-let MESSAGE = 'Tic Tock';
+const BASE_URL = "https://example.com/chrome/devtools/shared/webconsole/test/";
+const SERVICE_WORKER_URL = BASE_URL + "helper_serviceworker.js";
+const SCOPE = BASE_URL + "foo/";
+const NONSCOPE_FRAME_URL = BASE_URL + "sandboxed_iframe.html";
+const SCOPE_FRAME_URL = SCOPE + "fake.html";
+const SCOPE_FRAME_URL2 = SCOPE + "whatsit.html";
+const MESSAGE = 'Tic Tock';
 
-let expectedConsoleCalls = [
+const expectedConsoleCalls = [
     {
       level: "log",
       filename: /helper_serviceworker/,
       arguments: ['script evaluation'],
     },
     {
       level: "log",
       filename: /helper_serviceworker/,
@@ -95,31 +95,31 @@ let expectedConsoleCalls = [
     {
       level: "log",
       filename: /helper_serviceworker/,
       arguments: ['fetch event: ' + SCOPE_FRAME_URL2],
     },
 ];
 let consoleCalls = [];
 
-let startTest = async function () {
+const startTest = async function () {
   removeEventListener("load", startTest);
 
   await new Promise(resolve => {
     SpecialPowers.pushPrefEnv({"set": [
       ["dom.serviceWorkers.enabled", true],
       ["devtools.webconsole.filter.serviceworkers", true]
     ]}, resolve);
   });
 
   attachConsoleToTab(["ConsoleAPI"], onAttach);
 };
 addEventListener("load", startTest);
 
-let onAttach = async function (state, response) {
+const onAttach = async function (state, response) {
   onConsoleAPICall = onConsoleAPICall.bind(null, state);
   state.webConsoleFront.on("consoleAPICall", onConsoleAPICall);
 
   let currentFrame;
   try {
     // First, we need a frame from which to register our script.  This
     // will not trigger any console calls.
     info("Loading a non-scope frame from which to register a service worker.");
--- a/devtools/shared/webconsole/test/test_console_serviceworker_cached.html
+++ b/devtools/shared/webconsole/test/test_console_serviceworker_cached.html
@@ -9,21 +9,21 @@
      - http://creativecommons.org/publicdomain/zero/1.0/ -->
 </head>
 <body>
 <p>Test for getCachedMessages and Service Workers</p>
 
 <script class="testbody" type="text/javascript">
 SimpleTest.waitForExplicitFinish();
 
-let BASE_URL = "https://example.com/chrome/devtools/shared/webconsole/test/";
-let SERVICE_WORKER_URL = BASE_URL + "helper_serviceworker.js";
-let FRAME_URL = BASE_URL + "sandboxed_iframe.html";
+const BASE_URL = "https://example.com/chrome/devtools/shared/webconsole/test/";
+const SERVICE_WORKER_URL = BASE_URL + "helper_serviceworker.js";
+const FRAME_URL = BASE_URL + "sandboxed_iframe.html";
 
-let firstTabExpectedCalls = [
+const firstTabExpectedCalls = [
   {
     level: "log",
     filename: /helper_serviceworker/,
     arguments: ['script evaluation'],
   },
   {
     level: "log",
     filename: /helper_serviceworker/,
@@ -31,54 +31,54 @@ let firstTabExpectedCalls = [
   },
   {
     level: "log",
     filename: /helper_serviceworker/,
     arguments: ['activate event'],
   },
 ];
 
-let secondTabExpectedCalls = [
+const secondTabExpectedCalls = [
   {
     level: "log",
     filename: /helper_serviceworker/,
     arguments: ['fetch event: ' + FRAME_URL],
   }
 ];
 
-let startTest = async function () {
+const startTest = async function () {
   removeEventListener("load", startTest);
 
   await new Promise(resolve => {
     SpecialPowers.pushPrefEnv({"set": [
       ["dom.serviceWorkers.enabled", true],
       ["devtools.webconsole.filter.serviceworkers", true]
     ]}, resolve);
   });
 
   info("Adding a tab and attaching a service worker");
-  let tab1 = await addTab(FRAME_URL);
-  let swr = await withActiveServiceWorker(tab1.linkedBrowser.contentWindow,
+  const tab1 = await addTab(FRAME_URL);
+  const swr = await withActiveServiceWorker(tab1.linkedBrowser.contentWindow,
                                 SERVICE_WORKER_URL);
 
   await new Promise(resolve => {
     info("Attaching console to tab 1");
     attachConsoleToTab(["ConsoleAPI"], function(state) {
       state.webConsoleFront.getCachedMessages(["ConsoleAPI"]).then(function(calls) {
         checkConsoleAPICalls(calls.messages, firstTabExpectedCalls);
         closeDebugger(state, resolve);
       });
     });
   });
 
   // Because this tab is being added after the original messages happened,
   // they shouldn't show up in a call to getCachedMessages.
   // However, there is a fetch event which is logged due to loading the tab.
   info("Adding a new tab at the same URL");
-  let tab2 = await addTab(FRAME_URL);
+  const tab2 = await addTab(FRAME_URL);
   await new Promise(resolve => {
     info("Attaching console to tab 2");
     attachConsoleToTab(["ConsoleAPI"], function(state) {
       state.webConsoleFront.getCachedMessages(["ConsoleAPI"]).then(function(calls) {
         checkConsoleAPICalls(calls.messages, secondTabExpectedCalls);
         closeDebugger(state, resolve);
       });
     });
@@ -87,28 +87,28 @@ let startTest = async function () {
   await swr.unregister();
 
   SimpleTest.finish();
 };
 addEventListener("load", startTest);
 
 // This test needs to add tabs that are controlled by a service worker
 // so use some special powers to dig around and find gBrowser
-let {gBrowser} = SpecialPowers._getTopChromeWindow(SpecialPowers.window);
+const {gBrowser} = SpecialPowers._getTopChromeWindow(SpecialPowers.window);
 
 SimpleTest.registerCleanupFunction(() => {
   while (gBrowser.tabs.length > 1) {
     gBrowser.removeCurrentTab();
   }
 });
 
 function addTab(url) {
   info("Adding a new tab with URL: '" + url + "'");
   return new Promise(resolve => {
-    let tab = gBrowser.selectedTab = gBrowser.addTab(url, {
+    const tab = gBrowser.selectedTab = gBrowser.addTab(url, {
       triggeringPrincipal: Services.scriptSecurityManager.getSystemPrincipal(),
     });
     gBrowser.selectedBrowser.addEventListener("load", function () {
       info("URL '" + url + "' loading complete");
       resolve(tab);
     }, {capture: true, once: true});
   });
 }
--- a/devtools/shared/webconsole/test/test_console_worker.html
+++ b/devtools/shared/webconsole/test/test_console_worker.html
@@ -9,64 +9,64 @@
      - http://creativecommons.org/publicdomain/zero/1.0/ -->
 </head>
 <body>
 <p>Test for the Console API and Workers</p>
 
 <script class="testbody" type="text/javascript">
 SimpleTest.waitForExplicitFinish();
 
-let expectedCachedConsoleCalls = [
+const expectedCachedConsoleCalls = [
     {
       level: "log",
       filename: /console-test-worker/,
       arguments: ['Log from worker init'],
     },
 ];
 
-let expectedConsoleAPICalls = [
+const expectedConsoleAPICalls = [
     {
       level: "log",
       arguments: ['Log was requested from worker'],
     },
 ];
 
 window.onload = async function () {
-  let {state,response} = await new Promise(resolve => {
+  const {state,response} = await new Promise(resolve => {
     attachConsoleToWorker(["ConsoleAPI"], (state, response) => {
       resolve({state,response})
     });
   });
 
   await testCachedMessages(state);
   await testConsoleAPI(state);
 
   closeDebugger(state, function() {
     SimpleTest.finish();
   });
 };
 
-let testCachedMessages = async function (state) {
+const testCachedMessages = async function (state) {
   info("testCachedMessages entered");
   return new Promise(resolve => {
-    let onCachedConsoleAPI = (response) => {
-      let consoleCalls = response.messages;
+    const onCachedConsoleAPI = (response) => {
+      const consoleCalls = response.messages;
 
       info('Received cached response. Checking console calls.');
       checkConsoleAPICalls(consoleCalls, expectedCachedConsoleCalls);
       resolve();
     };
     state.webConsoleFront.getCachedMessages(["ConsoleAPI"]).then(onCachedConsoleAPI);
   })
 };
 
-let testConsoleAPI = async function (state) {
+const testConsoleAPI = async function (state) {
   info("testConsoleAPI entered");
   return new Promise(resolve => {
-    let onConsoleAPICall = (packet) => {
+    const onConsoleAPICall = (packet) => {
       info("received message level: " + packet.message.level);
       checkConsoleAPICalls([packet.message], expectedConsoleAPICalls);
       state.webConsoleFront.off("consoleAPICall", onConsoleAPICall);
       resolve();
     }
 
     info("testConsoleAPI: adding listener for consoleAPICall");
     state.webConsoleFront.on("consoleAPICall", onConsoleAPICall);
--- a/devtools/shared/webconsole/test/test_consoleapi.html
+++ b/devtools/shared/webconsole/test/test_consoleapi.html
@@ -13,33 +13,33 @@
 
 <script class="testbody" type="text/javascript">
 SimpleTest.waitForExplicitFinish();
 
 let expectedConsoleCalls = [];
 
 function doConsoleCalls(aState)
 {
-  let longString = (new Array(DebuggerServer.LONG_STRING_LENGTH + 2)).join("a");
+  const longString = (new Array(DebuggerServer.LONG_STRING_LENGTH + 2)).join("a");
 
   top.console.log("foobarBaz-log", undefined);
 
   top.console.log("Float from not a number: %f", "foo");
   top.console.log("Float from string: %f", "1.2");
   top.console.log("Float from number: %f", 1.3);
 
   top.console.info("foobarBaz-info", null);
   top.console.warn("foobarBaz-warn", top.document.documentElement);
   top.console.debug(null);
   top.console.trace();
   top.console.dir(top.document, top.location);
   top.console.log("foo", longString);
 
-  let sandbox = new Cu.Sandbox(null, { invisibleToDebugger: true });
-  let sandboxObj = sandbox.eval("new Object");
+  const sandbox = new Cu.Sandbox(null, { invisibleToDebugger: true });
+  const sandboxObj = sandbox.eval("new Object");
   top.console.log(sandboxObj);
 
   function fromAsmJS() {
       top.console.error("foobarBaz-asmjs-error", undefined);
   }
 
   (function(global, foreign) {
     "use asm";
--- a/devtools/shared/webconsole/test/test_consoleapi_innerID.html
+++ b/devtools/shared/webconsole/test/test_consoleapi_innerID.html
@@ -13,22 +13,22 @@
 
 <script class="testbody" type="text/javascript">
 SimpleTest.waitForExplicitFinish();
 
 let expectedConsoleCalls = [];
 
 function doConsoleCalls(aState)
 {
-  let { ConsoleAPI } = ChromeUtils.import("resource://gre/modules/Console.jsm");
-  let console = new ConsoleAPI({
+  const { ConsoleAPI } = ChromeUtils.import("resource://gre/modules/Console.jsm");
+  const console = new ConsoleAPI({
     innerID: window.windowUtils.currentInnerWindowID
   });
 
-  let longString = (new Array(DebuggerServer.LONG_STRING_LENGTH + 2)).join("a");
+  const longString = (new Array(DebuggerServer.LONG_STRING_LENGTH + 2)).join("a");
 
   console.log("foobarBaz-log", undefined);
   console.info("foobarBaz-info", null);
   console.warn("foobarBaz-warn", top.document.documentElement);
   console.debug(null);
   console.trace();
   console.dir(top.document, top.location);
   console.log("foo", longString);
--- a/devtools/shared/webconsole/test/test_file_uri.html
+++ b/devtools/shared/webconsole/test/test_file_uri.html
@@ -18,38 +18,38 @@ const {NetUtil} = ChromeUtils.import("re
 const {FileUtils} = ChromeUtils.import("resource://gre/modules/FileUtils.jsm");
 
 let gState;
 let gTmpFile;
 
 function doFileActivity()
 {
   info("doFileActivity");
-  let fileContent = "<p>hello world from bug 798764";
+  const fileContent = "<p>hello world from bug 798764";
 
   gTmpFile = FileUtils.getFile("TmpD", ["bug798764.html"]);
   gTmpFile.createUnique(Ci.nsIFile.NORMAL_FILE_TYPE, FileUtils.PERMS_FILE);
 
-  let fout = FileUtils.openSafeFileOutputStream(gTmpFile,
+  const fout = FileUtils.openSafeFileOutputStream(gTmpFile,
     FileUtils.MODE_WRONLY | FileUtils.MODE_CREATE | FileUtils.MODE_TRUNCATE);
 
-  let converter = Cc["@mozilla.org/intl/scriptableunicodeconverter"].
+  const converter = Cc["@mozilla.org/intl/scriptableunicodeconverter"].
                   createInstance(Ci.nsIScriptableUnicodeConverter);
   converter.charset = "UTF-8";
-  let fileContentStream = converter.convertToInputStream(fileContent);
+  const fileContentStream = converter.convertToInputStream(fileContent);
 
   NetUtil.asyncCopy(fileContentStream, fout, addIframe);
 }
 
 function addIframe(aStatus)
 {
   ok(Components.isSuccessCode(aStatus),
      "the temporary file was saved successfully");
 
-  let iframe = document.createElement("iframe");
+  const iframe = document.createElement("iframe");
   iframe.src = NetUtil.newURI(gTmpFile).spec;
   document.body.appendChild(iframe);
 }
 
 function startTest()
 {
   removeEventListener("load", startTest);
 
--- a/devtools/shared/webconsole/test/test_jsterm.html
+++ b/devtools/shared/webconsole/test/test_jsterm.html
@@ -13,22 +13,22 @@
 
 <iframe id="content-iframe" src="http://example.com/chrome/devtools/shared/webconsole/test/sandboxed_iframe.html"></iframe>
 
 <script class="testbody" type="text/javascript">
 SimpleTest.waitForExplicitFinish();
 
 let gState;
 
-let {MAX_AUTOCOMPLETE_ATTEMPTS,MAX_AUTOCOMPLETIONS} = require("devtools/shared/webconsole/js-property-provider");
+const {MAX_AUTOCOMPLETE_ATTEMPTS,MAX_AUTOCOMPLETIONS} = require("devtools/shared/webconsole/js-property-provider");
 
 
 function evaluateJS(input, options = {}) {
   return gState.webConsoleFront.evaluateJSAsync(input, options);
-}
+} 
 
 function startTest()
 {
   removeEventListener("load", startTest);
 
   attachConsoleToTab(["PageError"], onAttach);
 }
 
@@ -51,41 +51,41 @@ function onAttach(aState, aResponse)
 
   top.largeObject2 = Object.create(null);
   for (let i = 0; i < MAX_AUTOCOMPLETIONS * 2; i++) {
     top.largeObject2['a' + i] = i;
   }
 
   gState = aState;
 
-  let tests = [doSimpleEval, doWindowEval, doEvalWithException,
+  const tests = [doSimpleEval, doWindowEval, doEvalWithException,
                doEvalWithHelper, doEvalString, doEvalLongString,
                doEvalWithBinding, doEvalWithBindingFrame,
                forceLexicalInit];
 
   runTests(tests, testEnd);
 }
 
 async function doSimpleEval() {
   info("test eval '2+2'");
-  let response = await evaluateJS("2+2");
+  const response = await evaluateJS("2+2");
   checkObject(response, {
     input: "2+2",
     result: 4,
   });
 
   ok(!response.exception, "no eval exception");
   ok(!response.helperResult, "no helper result");
 
   nextTest();
 }
 
 async function doWindowEval() {
   info("test eval 'document'");
-  let response = await evaluateJS("document");
+  const response = await evaluateJS("document");
   checkObject(response, {
     input: "document",
     result: {
       type: "object",
       class: "HTMLDocument",
       actor: /[a-z]/,
     },
   });
@@ -93,100 +93,100 @@ async function doWindowEval() {
   ok(!response.exception, "no eval exception");
   ok(!response.helperResult, "no helper result");
 
   nextTest();
 }
 
 async function doEvalWithException() {
   info("test eval with exception");
-  let response = await evaluateJS("window.doTheImpossible()");
+  const response = await evaluateJS("window.doTheImpossible()");
   checkObject(response, {
     input: "window.doTheImpossible()",
     result: {
       type: "undefined",
     },
     exceptionMessage: /doTheImpossible/,
   });
 
   ok(response.exception, "js eval exception");
   ok(!response.helperResult, "no helper result");
 
   nextTest();
 }
 
 async function doEvalWithHelper() {
   info("test eval with helper");
-  let response = await evaluateJS("clear()");
+  const response = await evaluateJS("clear()");
   checkObject(response, {
     input: "clear()",
     result: {
       type: "undefined",
     },
     helperResult: { type: "clearOutput" },
   });
 
   ok(!response.exception, "no eval exception");
 
   nextTest();
 }
 
 async function doEvalString() {
-  let response = await evaluateJS("window.foobarObject.strfoo");
+  const response = await evaluateJS("window.foobarObject.strfoo");
   checkObject(response, {
     input: "window.foobarObject.strfoo",
     result: "foobarz",
   });
 
   nextTest();
 }
 
 async function doEvalLongString() {
-  let response = await evaluateJS("window.foobarObject.omgstr");
-  let str = top.foobarObject.omgstr;
-  let initial = str.substring(0, DebuggerServer.LONG_STRING_INITIAL_LENGTH);
+  const response = await evaluateJS("window.foobarObject.omgstr");
+  const str = top.foobarObject.omgstr;
+  const initial = str.substring(0, DebuggerServer.LONG_STRING_INITIAL_LENGTH);
 
   checkObject(response, {
     input: "window.foobarObject.omgstr",
     result: {
       type: "longString",
       initial: initial,
       length: str.length,
     },
   });
 
   nextTest();
 }
 
 async function doEvalWithBinding() {
-  let response = await evaluateJS("document;");
-  let documentActor = response.result.actor;
+  const response = await evaluateJS("document;");
+  const documentActor = response.result.actor;
 
   info("running a command with _self as document using selectedObjectActor");
-  let selectedObjectSame = await evaluateJS("_self === document", {
+  const selectedObjectSame = await evaluateJS("_self === document", {
     selectedObjectActor: documentActor
   });
   checkObject(selectedObjectSame, {
     result: true
   });
 
   nextTest();
 }
 
 async function doEvalWithBindingFrame() {
-  let frameWin = top.document.querySelector("iframe").contentWindow;
+  const frameWin = top.document.querySelector("iframe").contentWindow;
   frameWin.fooFrame = { bar: 1 };
 
-  let response = await evaluateJS(
+  const response = await evaluateJS(
     "document.querySelector('iframe').contentWindow.fooFrame"
   );
-  let iframeObjectActor = response.result.actor;
+  const iframeObjectActor = response.result.actor;
   ok(iframeObjectActor, "There is an actor associated with the response");
 
-  let selectedObjectGlobal = await evaluateJS("this.temp1 = _self;", {
+  const selectedObjectGlobal = await evaluateJS("this.temp1 = _self;", {
     selectedObjectActor: iframeObjectActor
   });
   ok(top.temp1 && top.temp1.bar === 1,
     "Global matches the top global with bindObjectActor");
   ok(!frameWin.temp1,
     "Global doesn't match the object's global with bindObjectActor");
 
   nextTest()
@@ -229,25 +229,25 @@ async function forceLexicalInit() {
         vars: ["xyz", "wb"]
     },
     {
         stmt: "let {c3pdoh=101} = null",
         vars: ["c3pdoh"]
     }
   ];
 
-  for (let data of testData) {
-      let response = await evaluateJS(data.stmt);
+  for (const data of testData) {
+      const response = await evaluateJS(data.stmt);
       checkObject(response, {
         input: data.stmt,
         result: undefined,
       });
       ok(response.exception, "expected exception");
-      for (let varName of data.vars) {
-          let response2 = await evaluateJS(varName);
+      for (const varName of data.vars) {
+          const response2 = await evaluateJS(varName);
           checkObject(response2, {
             input: varName,
             result: undefined,
           });
           ok(!response2.exception, "unexpected exception");
       }
   }
 
--- a/devtools/shared/webconsole/test/test_jsterm_autocomplete.html
+++ b/devtools/shared/webconsole/test/test_jsterm_autocomplete.html
@@ -133,106 +133,106 @@
     // environment chain (due to the webconsole helper functions defined there).
     await state.webConsoleFront.evaluateJSAsync(`this.proxy1 = null; this.proxy2 = null;`);
 
     await closeDebugger(state);
   }
 
   async function doAutocomplete1(webConsoleFront) {
     info("test autocomplete for 'window.foo'");
-    let response = await webConsoleFront.autocomplete("window.foo");
-    let matches = response.matches;
+    const response = await webConsoleFront.autocomplete("window.foo");
+    const matches = response.matches;
 
     is(response.matchProp, "foo", "matchProp");
     is(matches.length, 1, "matches.length");
     is(matches[0], "foobarObject", "matches[0]");
   }
 
   async function doAutocomplete2(webConsoleFront) {
     info("test autocomplete for 'window.foobarObject.'");
-    let response = await webConsoleFront.autocomplete("window.foobarObject.");
-    let matches = response.matches;
+    const response = await webConsoleFront.autocomplete("window.foobarObject.");
+    const matches = response.matches;
 
     ok(!response.matchProp, "matchProp");
     is(matches.length, 7, "matches.length");
     checkObject(matches,
       ["foo", "foobar", "foobaz", "omg", "omgfoo", "omgstr", "strfoo"]);
   }
 
   async function doAutocomplete3(webConsoleFront) {
     // Check that completion suggestions are offered inside the string.
     info("test autocomplete for 'dump(window.foobarObject.)'");
-    let response = await webConsoleFront.autocomplete("dump(window.foobarObject.)", 25);
-    let matches = response.matches;
+    const response = await webConsoleFront.autocomplete("dump(window.foobarObject.)", 25);
+    const matches = response.matches;
 
     ok(!response.matchProp, "matchProp");
     is(matches.length, 7, "matches.length");
     checkObject(matches,
       ["foo", "foobar", "foobaz", "omg", "omgfoo", "omgstr", "strfoo"]);
   }
 
   async function doAutocomplete4(webConsoleFront) {
     // Check that completion requests can have no suggestions.
     info("test autocomplete for 'dump(window.foobarObject.)'");
-    let response = await webConsoleFront.autocomplete("dump(window.foobarObject.)");
+    const response = await webConsoleFront.autocomplete("dump(window.foobarObject.)");
     ok(!response.matchProp, "matchProp");
     is(response.matches, null, "matches is null");
   }
 
   async function doAutocompleteLarge1(webConsoleFront) {
     // Check that completion requests with too large objects will
     // have no suggestions.
     info("test autocomplete for 'window.largeObject1.'");
-    let response = await webConsoleFront.autocomplete("window.largeObject1.");
+    const response = await webConsoleFront.autocomplete("window.largeObject1.");
     ok(!response.matchProp, "matchProp");
     info (response.matches.join("|"));
     is(response.matches.length, 0, "Bailed out with too many properties");
   }
 
   async function doAutocompleteLarge2(webConsoleFront) {
     // Check that completion requests with pretty large objects will
     // have MAX_AUTOCOMPLETIONS suggestions
     info("test autocomplete for 'window.largeObject2.'");
-    let response = await webConsoleFront.autocomplete("window.largeObject2.");
+    const response = await webConsoleFront.autocomplete("window.largeObject2.");
     ok(!response.matchProp, "matchProp");
     is(response.matches.length, MAX_AUTOCOMPLETIONS, "matches.length is MAX_AUTOCOMPLETIONS");
   }
 
   async function doAutocompleteProxyThrowsPrototype(webConsoleFront) {
     // Check that completion provides own properties even if [[GetPrototypeOf]] throws.
     info("test autocomplete for 'window.proxy1.'");
-    let response = await webConsoleFront.autocomplete("window.proxy1.");
+    const response = await webConsoleFront.autocomplete("window.proxy1.");
     ok(!response.matchProp, "matchProp");
     is(response.matches.length, 1, "matches.length");
     checkObject(response.matches, ["foo"]);
   }
 
   async function doAutocompleteProxyThrowsOwnKeys(webConsoleFront) {
     // Check that completion provides inherited properties even if [[OwnPropertyKeys]] throws.
     info("test autocomplete for 'window.proxy2.'");
-    let response = await webConsoleFront.autocomplete("window.proxy2.");
+    const response = await webConsoleFront.autocomplete("window.proxy2.");
     ok(!response.matchProp, "matchProp");
     is(response.matches.length, 1, "matches.length");
     checkObject(response.matches, ["foo"]);
   }
 
   async function doAutocompleteSandbox(webConsoleFront) {
     // Check that completion provides inherited properties even if [[OwnPropertyKeys]] throws.
     info("test autocomplete for 'Cu.Sandbox.'");
-    let response = await webConsoleFront.autocomplete("Cu.Sandbox.");
+    const response = await webConsoleFront.autocomplete("Cu.Sandbox.");
     ok(!response.matchProp, "matchProp");
-    let keys = Object.getOwnPropertyNames(Object.prototype).sort();
+    const keys = Object.getOwnPropertyNames(Object.prototype).sort();
     is(response.matches.length, keys.length, "matches.length");
     // checkObject(response.matches, keys);
     is(response.matches.join(" - "), keys.join(" - "));
   }
 
   async function doAutocompleteArray(webConsoleFront) {
     info("test autocomplete for [1,2,3]");
-    let response = await webConsoleFront.autocomplete("[1,2,3].");
+    const response = await webConsoleFront.autocomplete("[1,2,3].");
     let {matches} = response;
 
     ok(matches.length > 0, "There are completion results for the array");
     ok(matches.includes("length") && matches.includes("filter"),
       "Array autocomplete contains expected results");
 
     info("test autocomplete for '[] . '");
     matches = (await webConsoleFront.autocomplete("[] . ")).matches;
@@ -263,17 +263,17 @@
     matches = (await webConsoleFront.autocomplete("[1,2,3]['l")).matches;
     ok(matches.length >= 1);
     ok(matches.includes("'length'"),
       "Array autocomplete contains expected results, surrounded by quotes");
   }
 
   async function doAutocompleteString(webConsoleFront) {
     info(`test autocomplete for "foo".`);
-    let response = await webConsoleFront.autocomplete(`"foo".`);
+    const response = await webConsoleFront.autocomplete(`"foo".`);
     let {matches} = response;
 
     ok(matches.length > 0, "There are completion results for the string");
     ok(matches.includes("substr") && matches.includes("trim"),
       "String autocomplete contains expected results");
 
     info("test autocomplete for `foo`[");
     matches = (await webConsoleFront.autocomplete("`foo`[")).matches;
@@ -508,17 +508,17 @@
       "x=true?foob",
       "x=false?1:foob",
       "!foob",
       "false??foob",
     ];
 
     for (const input of inputs) {
       info(`test autocomplete for "${input}"`);
-      let matches = (await webConsoleFront.autocomplete(input)).matches;
+      const matches = (await webConsoleFront.autocomplete(input)).matches;
       ok(matches.includes("foobarObject"), `Expected autocomplete result for ${input}"`);
     }
   }
 
   async function dontAutocompleteAfterDeclaration(webConsoleFront) {
     info("test autocomplete for 'var win'");
     let matches = (await webConsoleFront.autocomplete("var win")).matches;
     is(matches, null, "no autocompletion on a var declaration");
@@ -604,17 +604,17 @@ async function doKeywordsAutocomplete(we
       "x=true?",
       "x=false?1:",
       "!",
       ...RESERVED_JS_KEYWORDS.map(keyword => `${keyword} `),
       ...RESERVED_JS_KEYWORDS.map(keyword => `${keyword}  `),
     ];
     for (const input of inputs) {
       info(`test autocomplete for "${input}"`);
-      let matches = (await webConsoleFront.autocomplete(input)).matches;
+      const matches = (await webConsoleFront.autocomplete(input)).matches;
       is(matches, null, `No autocomplete result for ${input}"`);
     }
   }
 
   async function getAutocompleteMatches(webConsoleFront, input) {
     info(`test autocomplete for "${input}"`);
     const res = (await webConsoleFront.autocomplete(input));
     return res.matches;
--- a/devtools/shared/webconsole/test/test_jsterm_cd_iframe.html
+++ b/devtools/shared/webconsole/test/test_jsterm_cd_iframe.html
@@ -30,17 +30,17 @@ function onAttach(aState, aResponse)
   top.foobarObject = Object.create(null);
   top.foobarObject.bug609872 = "parent";
 
   window.foobarObject = Object.create(null);
   window.foobarObject.bug609872 = "child";
 
   gState = aState;
 
-  let tests = [doCheckParent, doCdIframe, doCheckIframe,
+  const tests = [doCheckParent, doCdIframe, doCheckIframe,
       doCdContentIframe,
       doCdSandboxedIframe, doCheckSandboxedIframe,
       doCdParent,
       doCdParent,
       doCheckParent2];
   runTests(tests, testEnd);
 }
 
@@ -120,17 +120,17 @@ function onCdContentIframe(aResponse)
   ok(!aResponse.exception, "no eval exception");
 
   nextTest();
 }
 function doCdSandboxedIframe()
 {
   // Don't use string to ensure we don't get security exception
   // when passing a content window reference.
-  let cmd = "cd(document.getElementById('sandboxed-iframe').contentWindow)";
+  const cmd = "cd(document.getElementById('sandboxed-iframe').contentWindow)";
   info("test " + cmd);
   gState.webConsoleFront.evaluateJSAsync(cmd).then(onCdSandboxedIframe.bind(null, cmd));
 }
 
 function onCdSandboxedIframe(cmd, aResponse)
 {
   checkObject(aResponse, {
     input: cmd,
--- a/devtools/shared/webconsole/test/test_jsterm_last_result.html
+++ b/devtools/shared/webconsole/test/test_jsterm_last_result.html
@@ -21,46 +21,46 @@ function evaluateJS(input) {
   return gState.webConsoleFront.evaluateJSAsync(input);
 }
 
 function startTest()
 {
   removeEventListener("load", startTest);
   attachConsoleToTab([], state => {
     gState = state;
-    let tests = [checkUndefinedResult,checkAdditionResult,checkObjectResult];
+    const tests = [checkUndefinedResult,checkAdditionResult,checkObjectResult];
     runTests(tests, testEnd);
   });
 }
 
-let checkUndefinedResult = async function () {
+const checkUndefinedResult = async function () {
   info ("$_ returns undefined if nothing has evaluated yet");
-  let response = await evaluateJS("$_");
+  const response = await evaluateJS("$_");
   basicResultCheck(response, "$_", undefined);
   nextTest();
 };
 
-let checkAdditionResult = async function () {
+const checkAdditionResult = async function () {
   info ("$_ returns last value and performs basic arithmetic");
   let response = await evaluateJS("2+2");
   basicResultCheck(response, "2+2", 4);
 
   response = await evaluateJS("$_");
   basicResultCheck(response, "$_", 4);
 
   response = await evaluateJS("$_ + 2");
   basicResultCheck(response, "$_ + 2", 6);
 
   response = await evaluateJS("$_ + 4");
   basicResultCheck(response, "$_ + 4", 10);
 
   nextTest();
 };
 
-let checkObjectResult = async function () {
+const checkObjectResult = async function () {
   info ("$_ has correct references to objects");
 
   let response = await evaluateJS("var foo = {bar:1}; foo;");
   basicResultCheck(response, "var foo = {bar:1}; foo;", {
     type: "object",
     class: "Object",
     actor: /[a-z]/,
   });
--- a/devtools/shared/webconsole/test/test_jsterm_queryselector.html
+++ b/devtools/shared/webconsole/test/test_jsterm_queryselector.html
@@ -18,103 +18,103 @@ let gWin;
 
 function evaluateJS(input) {
   return gState.webConsoleFront.evaluateJSAsync(input);
 }
 
 function startTest() {
   info ("Content window opened, attaching console to it");
 
-  let systemPrincipal = Cc["@mozilla.org/systemprincipal;1"].createInstance(Ci.nsIPrincipal);
+  const systemPrincipal = Cc["@mozilla.org/systemprincipal;1"].createInstance(Ci.nsIPrincipal);
   ok (!gWin.document.nodePrincipal.equals(systemPrincipal),
       "The test document is not using the system principal");
 
   attachConsoleToTab([], state => {
     gState = state;
-    let tests = [
+    const tests = [
       setupWindow,
       checkQuerySelector,
       checkQuerySelectorAll,
       checkQuerySelectorAllNotExist,
       checkQuerySelectorException,
       checkQuerySelectorAllException
     ];
     runTests(tests, testEnd);
   });
 }
 
-let setupWindow = async function () {
+const setupWindow = async function () {
   info ("Shimming window functions for the content privileged tab");
   await evaluateJS("document.querySelector = function() { throw 'should not call qS'; }");
   await evaluateJS("document.querySelectorAll = function() { throw 'should not call qSA'; }");
   nextTest();
 };
 
-let checkQuerySelector = async function () {
+const checkQuerySelector = async function () {
   info ("$ returns an DOMNode");
-  let response = await evaluateJS("$('body')");
+  const response = await evaluateJS("$('body')");
   basicResultCheck(response, "$('body')", {
     type: "object",
     class: "HTMLBodyElement",
     preview: {
       kind: "DOMNode",
       nodeName: "body"
     }
   });
   nextTest();
 };
 
-let checkQuerySelectorAll = async function () {
+const checkQuerySelectorAll = async function () {
   info ("$$ returns an array");
-  let response = await evaluateJS("$$('body')");
+  const response = await evaluateJS("$$('body')");
   basicResultCheck(response, "$$('body')", {
     type: "object",
     class: "Array",
     preview: {
       length: 1
     }
   });
   nextTest();
 };
 
-let checkQuerySelectorAllNotExist = async function () {
+const checkQuerySelectorAllNotExist = async function () {
   info ("$$ returns an array even if query yields no results");
-  let response = await evaluateJS("$$('foobar')");
+  const response = await evaluateJS("$$('foobar')");
   basicResultCheck(response, "$$('foobar')", {
     type: "object",
     class: "Array",
     preview: {
       length: 0
     }
   });
   nextTest();
 };
 
-let checkQuerySelectorException = async function () {
+const checkQuerySelectorException = async function () {
   info ("$ returns an exception if an invalid selector was provided");
-  let response = await evaluateJS("$(':foo')");
+  const response = await evaluateJS("$(':foo')");
   checkObject(response, {
     input: "$(':foo')",
     exceptionMessage: "SyntaxError: ':foo' is not a valid selector",
     exception: {
       type: "object",
       class: "DOMException",
       preview: {
         kind: "DOMException",
         name: "SyntaxError",
         message: "':foo' is not a valid selector"
       }
     }
   });
   nextTest();
 };
 
-let checkQuerySelectorAllException = async function () {
+const checkQuerySelectorAllException = async function () {
   info ("$$ returns an exception if an invalid selector was provided");
-  let response = await evaluateJS("$$(':foo')");
+  const response = await evaluateJS("$$(':foo')");
   checkObject(response, {
     input: "$$(':foo')",
     exceptionMessage: "SyntaxError: ':foo' is not a valid selector",
     exception: {
       type: "object",
       class: "DOMException",
       preview: {
         kind: "DOMException",
@@ -139,17 +139,17 @@ function testEnd() {
   gWin.close();
   gWin = null;
   closeDebugger(gState, function() {
     gState = null;
     SimpleTest.finish();
   });
 }
 
-let load = async function () {
+const load = async function () {
   removeEventListener("load", load);
 
   await new Promise(resolve => {
     SpecialPowers.pushPrefEnv({"set": [
       ["security.data_uri.unique_opaque_origin", false],
     ]}, resolve);
   });
 
--- a/devtools/shared/webconsole/test/test_network_get.html
+++ b/devtools/shared/webconsole/test/test_network_get.html
@@ -26,39 +26,39 @@ function onAttach(aState, aResponse)
 {
   info("test network GET request");
 
   onNetworkEvent = onNetworkEvent.bind(null, aState);
   aState.webConsoleFront.on("serverNetworkEvent", onNetworkEvent);
   onNetworkEventUpdate = onNetworkEventUpdate.bind(null, aState);
   aState.dbgClient.on("networkEventUpdate", onNetworkEventUpdate);
 
-  let iframe = document.querySelector("iframe").contentWindow;
+  const iframe = document.querySelector("iframe").contentWindow;
   iframe.wrappedJSObject.testXhrGet();
 }
 
 function onNetworkEvent(aState, aPacket)
 {
   info("checking the network event packet");
 
-  let netActor = aPacket.eventActor;
+  const netActor = aPacket.eventActor;
 
   checkObject(netActor, {
     actor: /[a-z]/,
     startedDateTime: /^\d+\-\d+\-\d+T.+$/,
     url: /data\.json/,
     method: "GET",
   });
 
   aState.netActor = netActor.actor;
 
   aState.webConsoleFront.off("serverNetworkEvent", onNetworkEvent);
 }
 
-let updates = [];
+const updates = [];
 
 function onNetworkEventUpdate(aState, aPacket)
 {
   info("received networkEventUpdate " + aPacket.updateType);
   is(aPacket.from, aState.netActor, "networkEventUpdate actor");
 
   updates.push(aPacket.updateType);
 
--- a/devtools/shared/webconsole/test/test_network_post.html
+++ b/devtools/shared/webconsole/test/test_network_post.html
@@ -27,39 +27,39 @@ function onAttach(aState, aResponse)
 {
   info("test network POST request");
 
   onNetworkEvent = onNetworkEvent.bind(null, aState);
   aState.webConsoleFront.on("serverNetworkEvent", onNetworkEvent);
   onNetworkEventUpdate = onNetworkEventUpdate.bind(null, aState);
   aState.dbgClient.on("networkEventUpdate", onNetworkEventUpdate);
 
-  let iframe = document.querySelector("iframe").contentWindow;
+  const iframe = document.querySelector("iframe").contentWindow;
   iframe.wrappedJSObject.testXhrPost();
 }
 
 function onNetworkEvent(aState, aPacket)
 {
   info("checking the network event packet");
 
-  let netActor = aPacket.eventActor;
+  const netActor = aPacket.eventActor;
 
   checkObject(netActor, {
     actor: /[a-z]/,
     startedDateTime: /^\d+\-\d+\-\d+T.+$/,
     url: /data\.json/,
     method: "POST",
   });
 
   aState.netActor = netActor.actor;
 
   aState.webConsoleFront.off("serverNetworkEvent", onNetworkEvent);
 }
 
-let updates = [];
+const updates = [];
 
 function onNetworkEventUpdate(aState, aPacket)
 {
   info("received networkEventUpdate " + aPacket.updateType);
   is(aPacket.from, aState.netActor, "networkEventUpdate actor");
 
   updates.push(aPacket.updateType);
 
--- a/devtools/shared/webconsole/test/test_network_security-hpkp.html
+++ b/devtools/shared/webconsole/test/test_network_security-hpkp.html
@@ -43,23 +43,23 @@ const TEST_CASES = [
 function startTest() {
   Services.prefs.setBoolPref(HPKP_ENABLED_PREF, true);
   Services.prefs.setBoolPref(PROCESS_HPKP_FROM_NON_BUILTIN_ROOTS_PREF, true);
   SimpleTest.registerCleanupFunction(() => {
     Services.prefs.setBoolPref(HPKP_ENABLED_PREF, false);
     Services.prefs.setBoolPref(PROCESS_HPKP_FROM_NON_BUILTIN_ROOTS_PREF, false);
 
     // Reset pinning state.
-    let gSSService = Cc["@mozilla.org/ssservice;1"]
+    const gSSService = Cc["@mozilla.org/ssservice;1"]
                        .getService(Ci.nsISiteSecurityService);
 
-    let gIOService = Cc["@mozilla.org/network/io-service;1"]
+    const gIOService = Cc["@mozilla.org/network/io-service;1"]
                        .getService(Ci.nsIIOService);
-    for (let {url} of TEST_CASES) {
-      let uri = gIOService.newURI(url);
+    for (const {url} of TEST_CASES) {
+      const uri = gIOService.newURI(url);
       gSSService.resetState(Ci.nsISiteSecurityService.HEADER_HPKP, uri, 0);
     }
   });
 
   info("Test detection of Public Key Pinning.");
   removeEventListener("load", startTest);
   attachConsoleToTab(["NetworkActivity"], onAttach);
 }
@@ -74,26 +74,26 @@ function onAttach(state, response) {
 function runNextCase(state) {
   gCurrentTestCase++;
   if (gCurrentTestCase === TEST_CASES.length) {
     info("Tests ran. Cleaning up.");
     closeDebugger(state, SimpleTest.finish);
     return;
   }
 
-  let { desc, url } = TEST_CASES[gCurrentTestCase];
+  const { desc, url } = TEST_CASES[gCurrentTestCase];
   info("Testing site with " + desc);
 
-  let iframe = document.querySelector("iframe").contentWindow;
+  const iframe = document.querySelector("iframe").contentWindow;
   iframe.wrappedJSObject.makeXhrCallback("GET", url);
 }
 
 function onNetworkEventUpdate(state, packet) {
   function onSecurityInfo(received) {
-    let data = TEST_CASES[gCurrentTestCase];
+    const data = TEST_CASES[gCurrentTestCase];
     is(received.securityInfo.hpkp, data.usesPinning,
       "Public Key Pinning detected correctly.");
 
     runNextCase(state);
   }
 
   if (packet.updateType === "securityInfo") {
     state.webConsoleFront.getSecurityInfo(packet.from, onSecurityInfo);
--- a/devtools/shared/webconsole/test/test_network_security-hsts.html
+++ b/devtools/shared/webconsole/test/test_network_security-hsts.html
@@ -36,23 +36,23 @@ const TEST_CASES = [
   }
 ];
 
 function startTest()
 {
 
   SimpleTest.registerCleanupFunction(() => {
     // Reset HSTS state.
-    let gSSService = Cc["@mozilla.org/ssservice;1"]
+    const gSSService = Cc["@mozilla.org/ssservice;1"]
                        .getService(Ci.nsISiteSecurityService);
 
-    let gIOService = Cc["@mozilla.org/network/io-service;1"]
+    const gIOService = Cc["@mozilla.org/network/io-service;1"]
                        .getService(Ci.nsIIOService);
 
-    let uri = gIOService.newURI(TEST_CASES[0].url);
+    const uri = gIOService.newURI(TEST_CASES[0].url);
     gSSService.resetState(Ci.nsISiteSecurityService.HEADER_HSTS, uri, 0);
   });
 
   info("Test detection of HTTP Strict Transport Security.");
   removeEventListener("load", startTest);
   attachConsoleToTab(["NetworkActivity"], onAttach);
 }
 
@@ -67,27 +67,27 @@ function onAttach(aState, aResponse)
 function runNextCase(aState) {
   gCurrentTestCase++;
   if (gCurrentTestCase === TEST_CASES.length) {
     info("Tests ran. Cleaning up.");
     closeDebugger(aState, SimpleTest.finish);
     return;
   }
 
-  let { desc, url } = TEST_CASES[gCurrentTestCase];
+  const { desc, url } = TEST_CASES[gCurrentTestCase];
   info("Testing site with " + desc);
 
-  let iframe = document.querySelector("iframe").contentWindow;
+  const iframe = document.querySelector("iframe").contentWindow;
   iframe.wrappedJSObject.makeXhrCallback("GET", url);
 }
 
 function onNetworkEventUpdate(aState, aPacket)
 {
   function onSecurityInfo(packet) {
-    let data = TEST_CASES[gCurrentTestCase];
+    const data = TEST_CASES[gCurrentTestCase];
     is(packet.securityInfo.hsts, data.usesHSTS,
       "Strict Transport Security detected correctly.");
 
     runNextCase(aState);
   }
 
   if (aPacket.updateType === "securityInfo") {
     aState.webConsoleFront.getSecurityInfo(aPacket.from, onSecurityInfo);
--- a/devtools/shared/webconsole/test/test_nsiconsolemessage.html
+++ b/devtools/shared/webconsole/test/test_nsiconsolemessage.html
@@ -33,24 +33,24 @@ function onAttach(aState, aResponse)
     timeStamp: /^\d+$/,
   }];
 
   Services.console.logStringMessage("hello world! bug859756");
 
   info("waiting for messages");
 }
 
-let receivedMessages = [];
+const receivedMessages = [];
 
 function onLogMessage(aState, aPacket)
 {
   info("received message: " + aPacket.message);
 
   let found = false;
-  for (let expected of expectedMessages) {
+  for (const expected of expectedMessages) {
     if (expected.message == aPacket.message) {
       found = true;
       break;
     }
   }
   if (!found) {
     return;
   }
--- a/devtools/shared/webconsole/test/test_object_actor.html
+++ b/devtools/shared/webconsole/test/test_object_actor.html
@@ -24,22 +24,22 @@ function startTest() {
 
   attachConsoleToTab(["ConsoleAPI"], onAttach);
 }
 
 function onAttach(state, response) {
   onConsoleCall = onConsoleCall.bind(null, state);
   state.webConsoleFront.on("consoleAPICall", onConsoleCall);
 
-  let longString = (new Array(DebuggerServer.LONG_STRING_LENGTH + 3)).join("\u0629");
+  const longString = (new Array(DebuggerServer.LONG_STRING_LENGTH + 3)).join("\u0629");
 
   // Here we put the objects in the correct window, to avoid having them all
   // wrapped by proxies for cross-compartment access.
 
-  let foobarObject = top.Object.create(null);
+  const foobarObject = top.Object.create(null);
   foobarObject.tamarbuta = longString;
   foobarObject.foo = 1;
   foobarObject.foobar = "hello";
   foobarObject.omg = null;
   foobarObject.testfoo = false;
   foobarObject.notInspectable = top.Object.create(null);
   foobarObject.omgfn = new top.Function("return 'myResult'");
   foobarObject.abArray = new top.Array("a", "b");
@@ -144,25 +144,25 @@ function onConsoleCall(state, aPacket) {
       type: "object",
       actor: /[a-z]/,
     }],
   });
 
   state.webConsoleFront.off("consoleAPICall", onConsoleCall);
 
   info("inspecting object properties");
-  let args = aPacket.message.arguments;
+  const args = aPacket.message.arguments;
   onProperties = onProperties.bind(null, state);
 
-  let client = new ObjectFront(state.dbgClient, args[1]);
+  const client = new ObjectFront(state.dbgClient, args[1]);
   client.getPrototypeAndProperties().then(onProperties);
 }
 
 function onProperties(state, response) {
-  let props = response.ownProperties;
+  const props = response.ownProperties;
   is(Object.keys(props).length, Object.keys(expectedProps).length,
      "number of enumerable properties");
   checkObject(props, expectedProps);
 
   expectedProps = [];
 
   closeDebugger(state, function() {
     SimpleTest.finish();
--- a/devtools/shared/webconsole/test/test_object_actor_native_getters.html
+++ b/devtools/shared/webconsole/test/test_object_actor_native_getters.html
@@ -65,27 +65,27 @@ function onConsoleCall(aState, aPacket)
       type: "object",
       actor: /[a-z]/,
     }],
   });
 
   aState.webConsoleFront.off("consoleAPICall", onConsoleCall);
 
   info("inspecting object properties");
-  let args = aPacket.message.arguments;
+  const args = aPacket.message.arguments;
   onProperties = onProperties.bind(null, aState);
 
-  let client = new ObjectFront(aState.dbgClient, args[1]);
+  const client = new ObjectFront(aState.dbgClient, args[1]);
   client.getPrototypeAndProperties().then(onProperties);
 }
 
 function onProperties(aState, aResponse)
 {
-  let props = aResponse.ownProperties;
-  let keys = Object.keys(props);
+  const props = aResponse.ownProperties;
+  const keys = Object.keys(props);
   info(keys.length + " ownProperties: " + keys);
 
   ok(keys.length >= Object.keys(expectedProps).length, "number of properties");
 
   info("check ownProperties");
   checkObject(props, expectedProps);
   info("check safeGetterValues");
   checkObject(aResponse.safeGetterValues, expectedSafeGetters);
--- a/devtools/shared/webconsole/test/test_object_actor_native_getters_lenient_this.html
+++ b/devtools/shared/webconsole/test/test_object_actor_native_getters_lenient_this.html
@@ -22,17 +22,17 @@ function startTest()
   attachConsoleToTab(["ConsoleAPI"], onAttach);
 }
 
 function onAttach(aState, aResponse)
 {
   onConsoleCall = onConsoleCall.bind(null, aState);
   aState.webConsoleFront.on("consoleAPICall", onConsoleCall);
 
-  let docAsProto = Object.create(document);
+  const docAsProto = Object.create(document);
 
   top.console.log("hello", docAsProto);
 }
 
 function onConsoleCall(aState, aPacket)
 {
   info("checking the console API call packet");
 
@@ -44,26 +44,26 @@ function onConsoleCall(aState, aPacket)
       type: "object",
       actor: /[a-z]/,
     }],
   });
 
   aState.webConsoleFront.off("consoleAPICall", onConsoleCall);
 
   info("inspecting object properties");
-  let args = aPacket.message.arguments;
+  const args = aPacket.message.arguments;
   onProperties = onProperties.bind(null, aState);
 
-  let client = new ObjectFront(aState.dbgClient, args[1]);
+  const client = new ObjectFront(aState.dbgClient, args[1]);
   client.getPrototypeAndProperties().then(onProperties);
 }
 
 function onProperties(aState, aResponse)
 {
-  let props = aResponse.ownProperties;
+  const props = aResponse.ownProperties;
   let keys = Object.keys(props);
   info(keys.length + " ownProperties: " + keys);
 
   is(keys.length, 0, "number of properties");
   keys = Object.keys(aResponse.safeGetterValues);
   is(keys.length, 0, "number of safe getters");
 
   closeDebugger(aState, function() {
--- a/devtools/shared/webconsole/test/test_page_errors.html
+++ b/devtools/shared/webconsole/test/test_page_errors.html
@@ -127,17 +127,17 @@ function doPageErrors() {
             source: /test_page_errors/,
           }
         }
       ]
     },
   };
 
   let container = document.createElement("script");
-  for (let stmt of Object.keys(expectedPageErrors)) {
+  for (const stmt of Object.keys(expectedPageErrors)) {
       if (expectedPageErrors[stmt].exception) {
           SimpleTest.expectUncaughtException();
       }
       info("starting stmt: " + stmt);
       container = document.createElement("script");
       document.body.appendChild(container);
       container.textContent = stmt;
       document.body.removeChild(container);
@@ -152,17 +152,17 @@ function startTest() {
 }
 
 function onAttach(state, response) {
   onPageError = onPageError.bind(null, state);
   state.webConsoleFront.on("pageError", onPageError);
   doPageErrors();
 }
 
-let pageErrors = [];
+const pageErrors = [];
 
 function onPageError(state, packet) {
   if (!packet.pageError.sourceName.includes("test_page_errors")) {
     info("Ignoring error from unknown source: " + packet.pageError.sourceName);
     return;
   }
 
   pageErrors.push(packet.pageError);
--- a/devtools/shared/webconsole/test/test_throw.html
+++ b/devtools/shared/webconsole/test/test_throw.html
@@ -17,54 +17,54 @@ SimpleTest.waitForExplicitFinish();
 function startTest()
 {
   removeEventListener("load", startTest);
   attachConsoleToTab([], onAttach);
 }
 
 function onAttach(aState, aResponse)
 {
-  let tests = [];
+  const tests = [];
 
-  let falsyValues = ["-0", "null", "undefined", "Infinity", "-Infinity", "NaN"];
+  const falsyValues = ["-0", "null", "undefined", "Infinity", "-Infinity", "NaN"];
   falsyValues.forEach(function(value) {
     tests.push(async function() {
       const aResponse = await aState.webConsoleFront.evaluateJSAsync("throw " + value + ";")
-      let type = aResponse.exception.type;
+      const type = aResponse.exception.type;
       is(type, value, "exception.type for throw " + value);
       nextTest();
     });
   });
 
-  let identityTestValues = [false, 0];
+  const identityTestValues = [false, 0];
   identityTestValues.forEach(function(value) {
     tests.push(async function() {
       const aResponse = await aState.webConsoleFront.evaluateJSAsync("throw " + value + ";")
-      let exception = aResponse.exception;
+      const exception = aResponse.exception;
       is(exception, value, "response.exception for throw " + value);
       nextTest();
     });
   });
 
-  let longString = Array(DebuggerServer.LONG_STRING_LENGTH + 1).join("a"),
+  const longString = Array(DebuggerServer.LONG_STRING_LENGTH + 1).join("a"),
       shortedString = longString.substring(0,
                         DebuggerServer.LONG_STRING_INITIAL_LENGTH
                       );
   tests.push(async function() {
     const aResponse = await aState.webConsoleFront.evaluateJSAsync("throw '" + longString + "';")
     is(aResponse.exception.initial, shortedString,
       "exception.initial for throw longString"
     );
     is(aResponse.exceptionMessage.initial, shortedString,
       "exceptionMessage.initial for throw longString"
     );
     nextTest();
   });
 
-  let symbolTestValues = [
+  const symbolTestValues = [
     ["Symbol.iterator", "Symbol(Symbol.iterator)"],
     ["Symbol('foo')", "Symbol(foo)"],
     ["Symbol()", "Symbol()"],
   ];
   symbolTestValues.forEach(function([expr, message]) {
     tests.push(async function() {
       const aResponse = await aState.webConsoleFront.evaluateJSAsync("throw " + expr + ";");
       is(aResponse.exceptionMessage, message,