From 2dbc54f868210eaf9ed79de4a107ff197032ec78 Mon Sep 17 00:00:00 2001 From: Ruihui Yan Date: Fri, 29 Mar 2019 16:47:06 +0000 Subject: [PATCH] Bug 1508819 - Enable ESLint for dom/bindings (manual changes). r=nika Depends on D13891 Differential Revision: https://phabricator.services.mozilla.com/D13892 --HG-- extra : moz-landing-system : lando --- .eslintignore | 1 - dom/bindings/test/TestInterfaceJS.js | 1 + dom/bindings/test/file_bug775543.html | 2 +- dom/bindings/test/test_ByteString.html | 2 +- .../test/test_Object.prototype_props.html | 1 + dom/bindings/test/test_async_stacks.html | 1 + .../test/test_barewordGetsWindow.html | 2 +- dom/bindings/test/test_bug1036214.html | 3 +- .../test/test_bug1123516_maplikesetlike.html | 61 ++++++------ dom/bindings/test/test_bug1123875.html | 1 + dom/bindings/test/test_bug773326.html | 2 + dom/bindings/test/test_bug775543.html | 4 +- .../test_callback_across_document_open.html | 1 + .../test/test_callback_exceptions.html | 2 + .../test_crossOriginWindowSymbolAccess.html | 2 + dom/bindings/test/test_defineProperty.html | 4 +- dom/bindings/test/test_dom_xrays.html | 5 +- dom/bindings/test/test_enums.html | 1 + .../test/test_exceptionSanitization.html | 32 +++---- dom/bindings/test/test_exceptionThrowing.html | 8 +- .../test/test_exception_messages.html | 3 +- ..._exception_options_from_jsimplemented.html | 2 +- dom/bindings/test/test_forOf.html | 17 ++-- dom/bindings/test/test_iterable.html | 95 ++++++++++--------- .../test_jsimplemented_cross_realm_this.html | 1 + .../test/test_jsimplemented_eventhandler.html | 2 +- dom/bindings/test/test_lenientThis.html | 1 + .../test/test_named_getter_enumerability.html | 7 +- ...promise_rejections_from_jsimplemented.html | 4 +- dom/bindings/test/test_returnUnion.html | 2 +- .../test/test_sequence_detection.html | 2 +- dom/bindings/test/test_sequence_wrapping.html | 2 +- dom/bindings/test/test_stringBindings.html | 2 +- .../test/test_throwing_method_noDCE.html | 5 +- dom/bindings/test/test_toJSON.html | 2 +- .../test/test_unforgeablesonexpando.html | 1 + dom/bindings/test/test_usvstring.html | 2 + 37 files changed, 154 insertions(+), 132 deletions(-) diff --git a/.eslintignore b/.eslintignore index aaeca66ac124..6ac84fe1d179 100644 --- a/.eslintignore +++ b/.eslintignore @@ -161,7 +161,6 @@ dom/base/test/*.* dom/base/test/unit/test_serializers_entities*.js dom/base/test/unit_ipc/** dom/base/test/jsmodules/** -dom/bindings/** dom/canvas/** dom/encoding/** dom/events/** diff --git a/dom/bindings/test/TestInterfaceJS.js b/dom/bindings/test/TestInterfaceJS.js index 81c5c7e04c8d..744ed3a08a8a 100644 --- a/dom/bindings/test/TestInterfaceJS.js +++ b/dom/bindings/test/TestInterfaceJS.js @@ -2,6 +2,7 @@ /* This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this file, * You can obtain one at http://mozilla.org/MPL/2.0/. */ +/* global noSuchMethodExistsYo1, noSuchMethodExistsYo2, noSuchMethodExistsYo3 */ "use strict"; diff --git a/dom/bindings/test/file_bug775543.html b/dom/bindings/test/file_bug775543.html index ee8c14c4d9cc..856d14ab0e25 100644 --- a/dom/bindings/test/file_bug775543.html +++ b/dom/bindings/test/file_bug775543.html @@ -1,5 +1,5 @@ diff --git a/dom/bindings/test/test_ByteString.html b/dom/bindings/test/test_ByteString.html index 69c52662a479..2e5a70fb31f7 100644 --- a/dom/bindings/test/test_ByteString.html +++ b/dom/bindings/test/test_ByteString.html @@ -17,7 +17,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=796850 /** Test for Bug 796850 **/ var xhr = new XMLHttpRequest(); - caught = false; + var caught = false; try { xhr.open("\u5427", "about:mozilla", true); } catch (TypeError) { diff --git a/dom/bindings/test/test_Object.prototype_props.html b/dom/bindings/test/test_Object.prototype_props.html index 68aec1ea9c54..9791bbbdeba2 100644 --- a/dom/bindings/test/test_Object.prototype_props.html +++ b/dom/bindings/test/test_Object.prototype_props.html @@ -5,6 +5,7 @@
'>