summaryrefslogtreecommitdiff
path: root/test/common/index.js
diff options
context:
space:
mode:
authorRandal Hanford <rhanford@gmail.com>2017-10-06 10:51:12 -0700
committerJoyee Cheung <joyeec9h3@gmail.com>2017-10-15 00:47:06 +0800
commit971aad1b132a5ec37216c0d755d3ea59afc63812 (patch)
tree26d99c86895060b73c58ed47891c9dbd83e6723e /test/common/index.js
parent4826ac537f408304a8a208a2365d3bb415065c14 (diff)
downloadandroid-node-v8-971aad1b132a5ec37216c0d755d3ea59afc63812.tar.gz
android-node-v8-971aad1b132a5ec37216c0d755d3ea59afc63812.tar.bz2
android-node-v8-971aad1b132a5ec37216c0d755d3ea59afc63812.zip
test: use relative path in pipePrefix
Modified pipePrefix to use relative path on windows, previously tests failed when the full path was 120+ characters PR-URL: https://github.com/nodejs/node/pull/15988 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Diffstat (limited to 'test/common/index.js')
-rw-r--r--test/common/index.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/common/index.js b/test/common/index.js
index 278f9f6a78..05f21e25ca 100644
--- a/test/common/index.js
+++ b/test/common/index.js
@@ -258,7 +258,8 @@ Object.defineProperty(exports, 'hasFipsCrypto', {
});
{
- const pipePrefix = exports.isWindows ? '\\\\.\\pipe\\' : `${exports.tmpDir}/`;
+ const localRelative = path.relative(process.cwd(), `${exports.tmpDir}/`);
+ const pipePrefix = exports.isWindows ? '\\\\.\\pipe\\' : localRelative;
const pipeName = `node-test.${process.pid}.sock`;
exports.PIPE = pipePrefix + pipeName;
}