diff options
author | Rich Trott <rtrott@gmail.com> | 2016-03-26 19:33:48 -0700 |
---|---|---|
committer | Rich Trott <rtrott@gmail.com> | 2016-03-30 19:45:29 -0700 |
commit | 33c27f8fcffd7b0c6d609fdd4503b4f7a3c45bcd (patch) | |
tree | 92535f44eee16cd8026fd2417042cfc91e553282 /test/known_issues | |
parent | 21d66d621c5b1ce27498fcb1cb846fd34fce4234 (diff) | |
download | android-node-v8-33c27f8fcffd7b0c6d609fdd4503b4f7a3c45bcd.tar.gz android-node-v8-33c27f8fcffd7b0c6d609fdd4503b4f7a3c45bcd.tar.bz2 android-node-v8-33c27f8fcffd7b0c6d609fdd4503b4f7a3c45bcd.zip |
test: add known_issues test for GH-2148
PR-URL: https://github.com/nodejs/node/pull/5920
Refs: https://github.com/nodejs/node/issues/2148
Reviewed-By: Brian White <mscdex@mscdex.net>
Diffstat (limited to 'test/known_issues')
-rw-r--r-- | test/known_issues/test-stdout-buffer-flush-on-exit.js | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/test/known_issues/test-stdout-buffer-flush-on-exit.js b/test/known_issues/test-stdout-buffer-flush-on-exit.js new file mode 100644 index 0000000000..f4ea0b5e01 --- /dev/null +++ b/test/known_issues/test-stdout-buffer-flush-on-exit.js @@ -0,0 +1,20 @@ +'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); |