From 42c17f5596cc4504e9e68573e3611becbd78d3ea Mon Sep 17 00:00:00 2001 From: Rod Vagg Date: Wed, 3 Jun 2015 21:37:25 +1000 Subject: [PATCH] test: remove hardwired references to 'iojs' --- test/debugger/test-debugger-remote.js | 4 ++-- test/parallel/test-process-argv-0.js | 2 +- test/sequential/test-setproctitle.js | 4 +++- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/test/debugger/test-debugger-remote.js b/test/debugger/test-debugger-remote.js index abb67c19cbf0cd..81ed8b41ab0198 100644 --- a/test/debugger/test-debugger-remote.js +++ b/test/debugger/test-debugger-remote.js @@ -9,7 +9,7 @@ var expected = []; var scriptToDebug = common.fixturesDir + '/empty.js'; function fail() { - assert(0); // `iojs --debug-brk script.js` should not quit + assert(0); // `--debug-brk script.js` should not quit } // running with debug agent @@ -37,7 +37,7 @@ interfacer.on('line', function(line) { assert.ok(expected == line, 'Got unexpected line: ' + line); }); -// give iojs time to start up the debugger +// allow time to start up the debugger setTimeout(function() { child.removeListener('exit', fail); child.kill(); diff --git a/test/parallel/test-process-argv-0.js b/test/parallel/test-process-argv-0.js index 4bdb7ac3e71971..b67601a2556fee 100644 --- a/test/parallel/test-process-argv-0.js +++ b/test/parallel/test-process-argv-0.js @@ -9,7 +9,7 @@ console.error('argv=%j', process.argv); console.error('exec=%j', process.execPath); if (process.argv[2] !== 'child') { - var child = spawn('./iojs', [__filename, 'child'], { + var child = spawn(process.execPath, [__filename, 'child'], { cwd: path.dirname(process.execPath) }); diff --git a/test/sequential/test-setproctitle.js b/test/sequential/test-setproctitle.js index a0b15e2b85d8c3..61b3e470cded9e 100644 --- a/test/sequential/test-setproctitle.js +++ b/test/sequential/test-setproctitle.js @@ -10,6 +10,7 @@ if ('linux freebsd darwin'.indexOf(process.platform) === -1) { var common = require('../common'); var assert = require('assert'); var exec = require('child_process').exec; +var path = require('path'); // The title shouldn't be too long; libuv's uv_set_process_title() out of // security considerations no longer overwrites envp, only argv, so the @@ -25,7 +26,8 @@ exec('ps -p ' + process.pid + ' -o args=', function(error, stdout, stderr) { assert.equal(stderr, ''); // freebsd always add ' (procname)' to the process title - if (process.platform === 'freebsd') title += ' (iojs)'; + if (process.platform === 'freebsd') + title += ` (${path.basename(process.execPath)})`; // omitting trailing whitespace and \n assert.equal(stdout.replace(/\s+$/, ''), title);