test: add mustCallAtLeast to test-fs-read-stream-inherit
PR-URL: https://github.com/nodejs/node/pull/27457 Reviewed-By: Weijia Wang <starkwang@126.com> Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com> Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com>
This commit is contained in:
parent
c3d4933210
commit
f5e2ad784f
@ -26,7 +26,7 @@ const rangeFile = fixtures.path('x.txt');
|
||||
file.resume();
|
||||
}));
|
||||
|
||||
file.on('data', function(data) {
|
||||
file.on('data', common.mustCallAtLeast(function(data) {
|
||||
assert.ok(data instanceof Buffer);
|
||||
assert.ok(!paused);
|
||||
file.length += data.length;
|
||||
@ -38,7 +38,7 @@ const rangeFile = fixtures.path('x.txt');
|
||||
paused = false;
|
||||
file.resume();
|
||||
}, 10);
|
||||
});
|
||||
}));
|
||||
|
||||
|
||||
file.on('end', common.mustCall());
|
||||
|
Loading…
x
Reference in New Issue
Block a user