From 79dff99428c6377a8b5d300b0d071ce4d9f835a2 Mon Sep 17 00:00:00 2001 From: cjihrig Date: Wed, 26 Apr 2017 10:49:25 -0400 Subject: [PATCH] test: remove eslint comments from test-util.js PR-URL: https://github.com/nodejs/node/pull/12669 Reviewed-By: Refael Ackermann Reviewed-By: Alexey Orlenko Reviewed-By: Evan Lucas Reviewed-By: Gibson Fahnestock Reviewed-By: James M Snell Reviewed-By: Michael Dawson --- test/parallel/test-util.js | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/test/parallel/test-util.js b/test/parallel/test-util.js index 162191e9196e7c..242f91947440ae 100644 --- a/test/parallel/test-util.js +++ b/test/parallel/test-util.js @@ -31,8 +31,7 @@ assert.strictEqual(false, util.isRegExp(Object.create(RegExp.prototype))); // isDate assert.strictEqual(true, util.isDate(new Date())); assert.strictEqual(true, util.isDate(new Date(0))); -// eslint-disable-next-line new-parens -assert.strictEqual(true, util.isDate(new (context('Date')))); +assert.strictEqual(true, util.isDate(new (context('Date'))())); assert.strictEqual(false, util.isDate(Date())); assert.strictEqual(false, util.isDate({})); assert.strictEqual(false, util.isDate([])); @@ -43,11 +42,9 @@ assert.strictEqual(false, util.isDate(Object.create(Date.prototype))); assert.strictEqual(true, util.isError(new Error())); assert.strictEqual(true, util.isError(new TypeError())); assert.strictEqual(true, util.isError(new SyntaxError())); -/* eslint-disable new-parens */ -assert.strictEqual(true, util.isError(new (context('Error')))); -assert.strictEqual(true, util.isError(new (context('TypeError')))); -assert.strictEqual(true, util.isError(new (context('SyntaxError')))); -/* eslint-enable */ +assert.strictEqual(true, util.isError(new (context('Error'))())); +assert.strictEqual(true, util.isError(new (context('TypeError'))())); +assert.strictEqual(true, util.isError(new (context('SyntaxError'))())); assert.strictEqual(false, util.isError({})); assert.strictEqual(false, util.isError({ name: 'Error', message: '' })); assert.strictEqual(false, util.isError([]));