We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f9499ed commit f704d99Copy full SHA for f704d99
test/parallel/test-http2-pipe-named-pipe.js
@@ -22,12 +22,15 @@ const server = http2.createServer();
22
server.on('stream', common.mustCall((stream) => {
23
const dest = stream.pipe(fs.createWriteStream(fn));
24
25
- dest.on('finish', () => {
+ stream.on('end', common.mustCall(() => {
26
+ stream.respond();
27
+ stream.end();
28
+ }));
29
+
30
+ dest.on('finish', common.mustCall(() => {
31
assert.strictEqual(fs.readFileSync(loc).length,
32
fs.readFileSync(fn).length);
- });
- stream.respond();
- stream.end();
33
34
}));
35
36
server.listen(common.PIPE, common.mustCall(() => {
0 commit comments