mirror of
https://github.com/nodejs/node.git
synced 2026-11-21 12:59:16 -05:00
test: fix 2nd flaky blob test case
Signed-off-by: Tim Perry <pimterry@gmail.com> PR-URL: https://github.com/nodejs/node/pull/64391 Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
This commit is contained in:
1 parent
47b6ef28e6
commit
dca0fd1b69
1 file changed
+3
-1
@@ -384,7 +384,9 @@ assert.throws(() => new Blob({}), {
|
||||
assert.strictEqual(value.byteLength, 5);
|
||||
assert(!done);
|
||||
setTimeout(common.mustCall(() => {
|
||||
assert.strictEqual(stream[kState].controller.desiredSize, 0);
|
||||
// Same setImmediate() pull vs. timer race as the non-BYOB case above:
|
||||
// the stream may already have pulled the next 'hello' (5 bytes), hence -5.
|
||||
assert([0, -5].includes(stream[kState].controller.desiredSize));
|
||||
}), 0);
|
||||
})().then(common.mustCall());
|
||||
|
||||
|
||||
Reference in new issue
Block a user