Bug 1816182 - Stop applying ESLint test configuration to module files. r=Gijs,necko-reviewers

Differential Revision: https://phabricator.services.mozilla.com/D169513
This commit is contained in:
Mark Banner 2023-02-13 12:26:46 +00:00
parent 376311405d
commit 6c1ef05bb8
5 changed files with 21 additions and 3 deletions

View File

@ -138,6 +138,7 @@ module.exports = {
{
...removeOverrides(xpcshellTestConfig),
files: testPaths.xpcshell.map(path => `${path}**`),
excludedFiles: ["**/*.jsm", "**/*.mjs"],
},
{
// If it is an xpcshell head file, we turn off global unused variable checks, as it
@ -176,15 +177,21 @@ module.exports = {
{
...browserTestConfig,
files: testPaths.browser.map(path => `${path}**`),
excludedFiles: ["**/*.jsm", "**/*.mjs"],
},
{
...removeOverrides(mochitestTestConfig),
files: testPaths.mochitest.map(path => `${path}**`),
excludedFiles: ["security/manager/ssl/tests/mochitest/browser/**"],
excludedFiles: [
"**/*.jsm",
"**/*.mjs",
"security/manager/ssl/tests/mochitest/browser/**",
],
},
{
...removeOverrides(chromeTestConfig),
files: testPaths.chrome.map(path => `${path}**`),
excludedFiles: ["**/*.jsm", "**/*.mjs"],
},
{
env: {
@ -206,7 +213,7 @@ module.exports = {
},
{
// Bug 877389 - Gradually migrate from Cu.reportError to console.error.
// Report as warnings where it is not yet passing.
// Enable these as we fix more areas.
files: [
"dom/push/test/mockpushserviceparent.js",
"browser/components/extensions/**",

View File

@ -63,7 +63,7 @@ var AppMenu = {
async function reopenAppMenu(browserWindow) {
browserWindow.PanelUI.hide();
let promiseViewShown = BrowserTestUtils.waitForEvent(
PanelUI.panel,
browserWindow.PanelUI.panel,
"ViewShown"
);
browserWindow.PanelUI.show();

View File

@ -4,6 +4,9 @@
"use strict";
// Various parts here are run in the content process.
/* global content */
var EXPORTED_SYMBOLS = ["PermissionPrompts"];
const { BrowserTestUtils } = ChromeUtils.importESModule(

View File

@ -4,6 +4,9 @@
"use strict";
// Various parts here are run in the content process.
/* global content */
var EXPORTED_SYMBOLS = ["Preferences"];
const { TestUtils } = ChromeUtils.importESModule(

View File

@ -4,6 +4,11 @@
*/
"use strict";
// The functions in this file will run in the content process in a test
// scope.
/* eslint-env mozilla/simpletest */
/* global ContentTaskUtils, content */
const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
const { NetUtil } = ChromeUtils.import("resource://gre/modules/NetUtil.jsm");
const info = console.log;