Skip to content

Commit 6b91c78

Browse files
committed
test: reland changes from 11c1bae
Reland the changes from commit 11c1bae ("lib: make --debug-port work with cluster") that were temporarily backed out to cherry-pick commits from joyent/node. PR-URL: #501 Reviewed-By: Bert Belder <[email protected]> Reviewed-By: Rod Vagg <[email protected]>
1 parent 992a1e7 commit 6b91c78

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

test/parallel/test-debug-signal-cluster.js

+9-7
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,12 @@ var common = require('../common');
22
var assert = require('assert');
33
var spawn = require('child_process').spawn;
44

5-
var args = [ common.fixturesDir + '/clustered-server/app.js' ];
6-
var child = spawn(process.execPath, args, {
7-
stdio: [ 'pipe', 'pipe', 'pipe', 'ipc' ]
8-
});
5+
var port = common.PORT + 42;
6+
var args = ['--debug-port=' + port,
7+
common.fixturesDir + '/clustered-server/app.js'];
8+
var options = { stdio: ['inherit', 'inherit', 'pipe', 'ipc'] };
9+
var child = spawn(process.execPath, args, options);
10+
911
var outputLines = [];
1012
var outputTimerId;
1113
var waitingForDebuggers = false;
@@ -61,11 +63,11 @@ process.on('exit', function onExit() {
6163

6264
var expectedLines = [
6365
'Starting debugger agent.',
64-
'Debugger listening on port ' + 5858,
66+
'Debugger listening on port ' + (port + 0),
6567
'Starting debugger agent.',
66-
'Debugger listening on port ' + 5859,
68+
'Debugger listening on port ' + (port + 1),
6769
'Starting debugger agent.',
68-
'Debugger listening on port ' + 5860,
70+
'Debugger listening on port ' + (port + 2),
6971
];
7072

7173
function assertOutputLines() {

0 commit comments

Comments
 (0)