From 573cafe29da193d4c3e87ac228297ae1520fe7b2 Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Sat, 5 Feb 2022 07:05:20 -0800 Subject: [PATCH] test: remove eslint-disable comments from fixtures MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We do not lint the fixtures code so eslint-disable comments are superfluous. PR-URL: https://github.com/nodejs/node/pull/41859 Reviewed-By: Tobias Nießen Reviewed-By: Colin Ihrig Reviewed-By: James M Snell Reviewed-By: Mestery Reviewed-By: Luigi Pinca --- test/fixtures/es-module-loaders/loader-invalid-url.mjs | 1 - test/fixtures/es-module-loaders/throw-undefined.mjs | 1 - test/fixtures/es-modules/import-json-named-export.mjs | 1 - test/fixtures/wpt/streams/readable-streams/general.any.js | 1 - .../fixtures/wpt/streams/readable-streams/patched-global.any.js | 1 - test/fixtures/wpt/streams/resources/test-utils.js | 1 - .../wpt/streams/transform-streams/patched-global.any.js | 2 -- 7 files changed, 8 deletions(-) diff --git a/test/fixtures/es-module-loaders/loader-invalid-url.mjs b/test/fixtures/es-module-loaders/loader-invalid-url.mjs index ad69faff26d40f..a7cefeca3da37a 100644 --- a/test/fixtures/es-module-loaders/loader-invalid-url.mjs +++ b/test/fixtures/es-module-loaders/loader-invalid-url.mjs @@ -1,4 +1,3 @@ -/* eslint-disable node-core/required-modules */ export async function resolve(specifier, { parentURL, importAssertions }, defaultResolve) { if (parentURL && specifier === '../fixtures/es-modules/test-esm-ok.mjs') { return { diff --git a/test/fixtures/es-module-loaders/throw-undefined.mjs b/test/fixtures/es-module-loaders/throw-undefined.mjs index 0349ae112d6b2d..f062276767408d 100644 --- a/test/fixtures/es-module-loaders/throw-undefined.mjs +++ b/test/fixtures/es-module-loaders/throw-undefined.mjs @@ -1,4 +1,3 @@ 'use strict'; -/* eslint-disable node-core/required-modules */ throw undefined; diff --git a/test/fixtures/es-modules/import-json-named-export.mjs b/test/fixtures/es-modules/import-json-named-export.mjs index f491e8c252d41a..01798c59ac587d 100644 --- a/test/fixtures/es-modules/import-json-named-export.mjs +++ b/test/fixtures/es-modules/import-json-named-export.mjs @@ -1,2 +1 @@ -/* eslint-disable no-unused-vars */ import { ofLife } from '../experimental.json' assert { type: 'json' }; diff --git a/test/fixtures/wpt/streams/readable-streams/general.any.js b/test/fixtures/wpt/streams/readable-streams/general.any.js index 4e54990823ab01..efe7da74ad6c08 100644 --- a/test/fixtures/wpt/streams/readable-streams/general.any.js +++ b/test/fixtures/wpt/streams/readable-streams/general.any.js @@ -630,7 +630,6 @@ promise_test(() => { let pullCalled = 0; let cancelCalled = 0; - /* eslint-disable no-use-before-define */ class Source { start(c) { startCalled++; diff --git a/test/fixtures/wpt/streams/readable-streams/patched-global.any.js b/test/fixtures/wpt/streams/readable-streams/patched-global.any.js index 576a39f6777e2b..d26dc56cfe6953 100644 --- a/test/fixtures/wpt/streams/readable-streams/patched-global.any.js +++ b/test/fixtures/wpt/streams/readable-streams/patched-global.any.js @@ -22,7 +22,6 @@ test(t => { const trappedProperties = ['highWaterMark', 'size', 'start', 'type', 'mode']; for (const property of trappedProperties) { - // eslint-disable-next-line no-extend-native, accessor-pairs Object.defineProperty(Object.prototype, property, { get() { throw new Error(`${property} getter called`); }, configurable: true diff --git a/test/fixtures/wpt/streams/resources/test-utils.js b/test/fixtures/wpt/streams/resources/test-utils.js index 0593980e1055b5..97d4261aa0507a 100644 --- a/test/fixtures/wpt/streams/resources/test-utils.js +++ b/test/fixtures/wpt/streams/resources/test-utils.js @@ -57,7 +57,6 @@ self.garbageCollect = () => { // Present in some WebKit development environments GCController.collect(); } else { - /* eslint-disable no-console */ console.warn('Tests are running without the ability to do manual garbage collection. They will still work, but ' + 'coverage will be suboptimal.'); /* eslint-enable no-console */ diff --git a/test/fixtures/wpt/streams/transform-streams/patched-global.any.js b/test/fixtures/wpt/streams/transform-streams/patched-global.any.js index 5142d236fb65e8..5bce0cb41ce437 100644 --- a/test/fixtures/wpt/streams/transform-streams/patched-global.any.js +++ b/test/fixtures/wpt/streams/transform-streams/patched-global.any.js @@ -5,13 +5,11 @@ // interfering with other tests. test(t => { - // eslint-disable-next-line no-extend-native, accessor-pairs Object.defineProperty(Object.prototype, 'highWaterMark', { set() { throw new Error('highWaterMark setter called'); }, configurable: true }); - // eslint-disable-next-line no-extend-native, accessor-pairs Object.defineProperty(Object.prototype, 'size', { set() { throw new Error('size setter called'); }, configurable: true