mirror of https://github.com/lukechilds/node.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
16 lines
366 B
16 lines
366 B
8 years ago
|
'use strict';
|
||
|
|
||
8 years ago
|
const common = require('../common');
|
||
|
common.skipIfInspectorDisabled();
|
||
8 years ago
|
const spawn = require('child_process').spawn;
|
||
|
|
||
8 years ago
|
const proc = spawn(process.execPath, ['inspect', 'foo']);
|
||
8 years ago
|
proc.stdout.setEncoding('utf8');
|
||
|
|
||
8 years ago
|
let output = '';
|
||
|
proc.stdout.on('data', (data) => {
|
||
|
output += data;
|
||
|
if (output.includes('debug> '))
|
||
7 years ago
|
proc.stdin.write('.exit\n');
|
||
8 years ago
|
});
|