Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
win, test: escape script filename on Windows
Escape backslashes in script filename on Windows in a CLI test.

Fixes: #16057
Fixes: #16023
  • Loading branch information
bzoz committed Oct 10, 2017
commit 8f87a8a16b635e4f8a6c0b6bb7ae1c77a5440995
5 changes: 4 additions & 1 deletion test/parallel/test-cli-eval.js
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,10 @@ child.exec(`${nodejs} --use-strict -p process.execArgv`,

// Regression test for https://github.com/nodejs/node/issues/3574.
{
const emptyFile = fixtures.path('empty.js');
let emptyFile = fixtures.path('empty.js');
if (common.isWindows) {
emptyFile = emptyFile.replace(/\\/g, '\\\\');
}

child.exec(`${nodejs} -e 'require("child_process").fork("${emptyFile}")'`,
common.mustCall((err, stdout, stderr) => {
Expand Down