summaryrefslogtreecommitdiff
path: root/test/parallel/test-stdin-child-proc.js
blob: bbb6a29cd724c9758d96e41ab653bde5131784b9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
'use strict';
// This tests that pausing and resuming stdin does not hang and timeout
// when done in a child process.  See test/parallel/test-stdin-pause-resume.js
const common = require('../common');
const assert = require('assert');
const child_process = require('child_process');
const path = require('path');
const cp = child_process.spawn(
  process.execPath,
  [path.resolve(__dirname, 'test-stdin-pause-resume.js')]
);

cp.on('exit', common.mustCall((code) => {
  assert.strictEqual(code, 0);
}));