test: fix setproctitle on FreeBSD

PR-URL: https://github.com/iojs/io.js/pull/332
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
This commit is contained in:
Fedor Indutny 2015-01-13 16:28:56 +03:00
parent ccc91aea35
commit 27e9ed6e98

View File

@ -24,7 +24,7 @@ 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 += ' (node)';
if (process.platform === 'freebsd') title += ' (iojs)';
// omitting trailing whitespace and \n
assert.equal(stdout.replace(/\s+$/, ''), title);