Skip to content

Commit 357eaf3

Browse files
cjihrigtargos
authored andcommitted
test: lint fixes for ESLint update
This commit introduces changes required for the ESLint 5 update. PR-URL: #20855 Reviewed-By: Rich Trott <rtrott@gmail.com>
1 parent bfac7be commit 357eaf3

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

test/es-module/test-esm-forbidden-globals.mjs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
// Flags: --experimental-modules
22
import '../common';
33

4+
// eslint-disable-next-line no-undef
45
if (typeof arguments !== 'undefined') {
56
throw new Error('not an ESM');
67
}

test/parallel/test-console-is-a-namespace.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@ require('../common');
55
const { test, assert_equals, assert_true, assert_false } =
66
require('../common/wpt');
77

8-
global.console = global.console; // Should not throw.
8+
// Assigning to itself should not throw.
9+
global.console = global.console; // eslint-disable-line no-self-assign
910

1011
const self = global;
1112

test/parallel/test-http2-socket-proxy.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,8 @@ server.on('stream', common.mustCall(function(stream, headers) {
5252
common.expectsError(() => (socket.write = undefined), errMsg);
5353

5454
// Resetting the socket listeners to their own value should not throw.
55-
socket.on = socket.on;
56-
socket.once = socket.once;
55+
socket.on = socket.on; // eslint-disable-line no-self-assign
56+
socket.once = socket.once; // eslint-disable-line no-self-assign
5757

5858
stream.respond();
5959

0 commit comments

Comments
 (0)