diff --git a/test/common/child_process.js b/test/common/child_process.js index a3dc0639875c9a..d555d09a944c1c 100644 --- a/test/common/child_process.js +++ b/test/common/child_process.js @@ -3,7 +3,6 @@ const assert = require('assert'); const { spawnSync, execFileSync } = require('child_process'); const common = require('./'); -const os = require('os'); const util = require('util'); // Workaround for Windows Server 2008R2 @@ -44,13 +43,6 @@ function logAfterTime(time) { } function checkOutput(str, check) { - if (common.isWindows && typeof str === 'string') { - // Normalize the line endings for the output and the check strings. - str = str.replaceAll(os.EOL, '\n'); - if (typeof check === 'string') { - check = check.replaceAll(os.EOL, '\n'); - } - } if ((check instanceof RegExp && !check.test(str)) || (typeof check === 'string' && check !== str)) { return { passed: false, reason: `did not match ${util.inspect(check)}` }; diff --git a/test/embedding/test-embedding.js b/test/embedding/test-embedding.js index 1a579a11edc8b6..71c4f7f324c973 100644 --- a/test/embedding/test-embedding.js +++ b/test/embedding/test-embedding.js @@ -10,6 +10,7 @@ const { } = require('../common/child_process'); const path = require('path'); const fs = require('fs'); +const os = require('os'); tmpdir.refresh(); common.allowGlobals(global.require); @@ -166,6 +167,6 @@ for (const extraSnapshotArgs of [ { status: 9, signal: null, - stderr: `${binary}: NODE_REPL_EXTERNAL_MODULE can't be used with kDisableNodeOptionsEnv\n`, + stderr: `${binary}: NODE_REPL_EXTERNAL_MODULE can't be used with kDisableNodeOptionsEnv${os.EOL}`, }); }