зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1813377 - Clean up XPCNativeWrapper globals handling for ESLint. r=mccr8
XPCNativeWrapper may be going away (bug 1481337). Stop defining it in the main environments and only define it where necessary to discourage more uses. This also helps to clarify the ESLint test environment globals. Differential Revision: https://phabricator.services.mozilla.com/D168211
This commit is contained in:
Родитель
e1d65f08eb
Коммит
106725dcfc
|
@ -20,7 +20,6 @@ module.exports = {
|
|||
loader: true,
|
||||
Services: true,
|
||||
Task: true,
|
||||
XPCNativeWrapper: true,
|
||||
XPCOMUtils: true,
|
||||
_Iterator: true,
|
||||
__dirname: true,
|
||||
|
|
|
@ -3,6 +3,10 @@
|
|||
|
||||
// Ensure that same-origin errors are logged to the console.
|
||||
|
||||
// XPCNativeWrapper is not defined globally in ESLint as it may be going away.
|
||||
// See bug 1481337.
|
||||
/* global XPCNativeWrapper */
|
||||
|
||||
"use strict";
|
||||
|
||||
const TEST_URI =
|
||||
|
|
|
@ -3,6 +3,10 @@
|
|||
|
||||
// Ensure that same-origin errors are logged to the console.
|
||||
|
||||
// XPCNativeWrapper is not defined globally in ESLint as it may be going away.
|
||||
// See bug 1481337.
|
||||
/* global XPCNativeWrapper */
|
||||
|
||||
"use strict";
|
||||
|
||||
const TEST_URI =
|
||||
|
|
|
@ -2,6 +2,8 @@
|
|||
* 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/. */
|
||||
|
||||
// XPCNativeWrapper is not defined globally in ESLint as it may be going away.
|
||||
// See bug 1481337.
|
||||
/* global XPCNativeWrapper */
|
||||
|
||||
"use strict";
|
||||
|
|
|
@ -18,6 +18,10 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=533596
|
|||
<!-- test code goes here -->
|
||||
<script type="application/javascript"><![CDATA[
|
||||
|
||||
// XPCNativeWrapper is not defined globally in ESLint as it may be going away.
|
||||
// See bug 1481337.
|
||||
/* global XPCNativeWrapper */
|
||||
|
||||
/** Test for Bug 533596 **/
|
||||
|
||||
function go() {
|
||||
|
|
|
@ -12,6 +12,8 @@
|
|||
* chrome-privileged scripts when they need to interact with privileged APIs.
|
||||
*/
|
||||
|
||||
// XPCNativeWrapper is not defined globally in ESLint as it may be going away.
|
||||
// See bug 1481337.
|
||||
/* globals XPCNativeWrapper */
|
||||
|
||||
Cu.crashIfNotInAutomation();
|
||||
|
|
|
@ -23,7 +23,6 @@ module.exports = {
|
|||
PromiseDebugging: false,
|
||||
SpecialPowers: false,
|
||||
TestUtils: false,
|
||||
XPCNativeWrapper: false,
|
||||
addLoadEvent: false,
|
||||
add_setup: false,
|
||||
add_task: false,
|
||||
|
|
|
@ -11,7 +11,6 @@ module.exports = {
|
|||
globals: {
|
||||
// SpecialPowers is injected into the window object via SimpleTest.js
|
||||
SpecialPowers: false,
|
||||
XPCNativeWrapper: false,
|
||||
extractJarToTmp: false,
|
||||
getChromeDir: false,
|
||||
getJar: false,
|
||||
|
|
|
@ -10,7 +10,6 @@ module.exports = {
|
|||
globals: {
|
||||
// SpecialPowers is injected into the window object via SimpleTest.js
|
||||
SpecialPowers: false,
|
||||
XPCNativeWrapper: false,
|
||||
},
|
||||
|
||||
overrides: [
|
||||
|
|
Загрузка…
Ссылка в новой задаче