Skip to content

Commit 5443a22

Browse files
committed
fixup
1 parent 48ea4c2 commit 5443a22

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

test/parallel/test-stream-writable-end-cb-error.js

+6
Original file line numberDiff line numberDiff line change
@@ -57,11 +57,17 @@ const stream = require('stream');
5757
}
5858
});
5959
w.end('testing ended state', common.mustCall((err) => {
60+
// This errors since .destroy(err), which is invoked by errors
61+
// in same tick below, will error all pending callbacks.
62+
// Does this make sense? Not sure.
6063
assert.strictEqual(err.code, 'ERR_STREAM_DESTROYED');
6164
}));
6265
assert.strictEqual(w.destroyed, false);
6366
assert.strictEqual(w.writableEnded, true);
6467
w.end(common.mustCall((err) => {
68+
// This errors since .destroy(err), which is invoked by errors
69+
// in same tick below, will error all pending callbacks.
70+
// Does this make sense? Not sure.
6571
assert.strictEqual(err.code, 'ERR_STREAM_DESTROYED');
6672
}));
6773
assert.strictEqual(w.destroyed, false);

0 commit comments

Comments
 (0)