aboutsummaryrefslogtreecommitdiff
path: root/test/bun.js/node-test-helpers.js
diff options
context:
space:
mode:
authorGravatar Derrick Farris <mr.dcfarris@gmail.com> 2022-12-02 10:25:13 -0600
committerGravatar GitHub <noreply@github.com> 2022-12-02 08:25:13 -0800
commitb8586b33dad8ab66ebd5d1aa4d5a0df305266e7f (patch)
tree19c31806b3ae22d7c0f0f127fd3cb1b640f4bd59 /test/bun.js/node-test-helpers.js
parentbeaf91590acd319e4ac15c14c64c59f45b6a794b (diff)
downloadbun-b8586b33dad8ab66ebd5d1aa4d5a0df305266e7f.tar.gz
bun-b8586b33dad8ab66ebd5d1aa4d5a0df305266e7f.tar.zst
bun-b8586b33dad8ab66ebd5d1aa4d5a0df305266e7f.zip
feat(process): add process.{stdin, stdout, stderr} support (#1495)
* fix(stream): get Duplex working * feat(process): add stdin,stdout,stderr in a semi-broken state (pipes??) * test(NodeTestHelpers): fix test names * test(NodeTestHelpers): add test for createDoneDotAll done called w error * test(NodeTestHelpers): remove stray console.log * fix(stream): fix bug in Duplex, Readable * test(process.stdio): rename test * fix(process.stdio): change onData listener to onReadable * refactor(streams): add file-wide debug fn, destructure opts * fix(child_process): check isCallable on promise * fix: get stdio streams mostly working (mostly) * fix(child_process): wait until stream is drained before calling end? * fix(child_process): change to result?.then * debug(child_process,streams): add EE id tracking, add shim for stdio after handle is dead * test(child_process): fix double pipe test, temp fix for ChildProcess.kill() return val * fix(child_process): remove immediate emit of exit on kill * debug(streams): add more debug log * debug(streams): add more debug logs part 2 * feat(streams,fs): add NativeWritable, adapt fs.WriteStream and fs.ReadStream to native
Diffstat (limited to 'test/bun.js/node-test-helpers.js')
-rw-r--r--test/bun.js/node-test-helpers.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/test/bun.js/node-test-helpers.js b/test/bun.js/node-test-helpers.js
index 0ebd6bc4f..f62f1ab3b 100644
--- a/test/bun.js/node-test-helpers.js
+++ b/test/bun.js/node-test-helpers.js
@@ -136,7 +136,10 @@ export function createDoneDotAll(done) {
let completed = 0;
function createDoneCb(timeout) {
toComplete += 1;
- const timer = setTimeout(() => done(new Error("Timed out!")), timeout);
+ const timer = setTimeout(() => {
+ console.log("Timeout");
+ done(new Error("Timed out!"));
+ }, timeout);
return (result) => {
clearTimeout(timer);
if (result instanceof Error) {