Bug 1536659 - docshell/ manual ESLint no-throw-literal fixes. r=nika

Differential Revision: https://phabricator.services.mozilla.com/D24368

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Ian Moody 2019-03-21 22:40:36 +00:00
parent b6cbc669dc
commit 3e2a03dd32
2 changed files with 2 additions and 4 deletions

View File

@ -55,8 +55,6 @@ module.exports = {
}, {
// TODO: Bug 1246594. Empty this list once the rule has landed for all dirs
"files": [
"docshell/test/chrome/docshell_helpers.js",
"docshell/test/navigation/NavigationUtils.js",
"dom/asmjscache/test/**",
"dom/cache/test/mochitest/test_cache_tons_of_fd.html",
"dom/crypto/test/**",

View File

@ -148,8 +148,8 @@ function doPageNavigation(params) {
}
}
if (!eventFound)
throw "Event type " + anEventType + " is specified in " +
"eventsToListenFor, but not in expectedEvents";
throw new Error(`Event type ${anEventType} is specified in ` +
"eventsToListenFor, but not in expectedEvents");
}
// If the test explicitly sets .eventsToListenFor to [], don't wait for any