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.
21 lines
505 B
21 lines
505 B
9 years ago
|
'use strict';
|
||
|
// Refs: https://github.com/nodejs/node/issues/2148
|
||
|
|
||
|
require('../common');
|
||
|
const assert = require('assert');
|
||
|
const execSync = require('child_process').execSync;
|
||
|
|
||
|
const longLine = 'foo bar baz quux quuz aaa bbb ccc'.repeat(65536);
|
||
|
|
||
|
if (process.argv[2] === 'child') {
|
||
|
process.on('exit', () => {
|
||
|
console.log(longLine);
|
||
|
});
|
||
|
process.exit();
|
||
|
}
|
||
|
|
||
|
const cmd = `${process.execPath} ${__filename} child`;
|
||
|
const stdout = execSync(cmd).toString().trim();
|
||
|
|
||
|
assert.strictEqual(stdout, longLine);
|