summaryrefslogtreecommitdiff
path: root/tests/node_compat/test/parallel/test-stream2-writable.js
diff options
context:
space:
mode:
Diffstat (limited to 'tests/node_compat/test/parallel/test-stream2-writable.js')
-rw-r--r--tests/node_compat/test/parallel/test-stream2-writable.js11
1 files changed, 8 insertions, 3 deletions
diff --git a/tests/node_compat/test/parallel/test-stream2-writable.js b/tests/node_compat/test/parallel/test-stream2-writable.js
index 665ff507f..4f5ba53fc 100644
--- a/tests/node_compat/test/parallel/test-stream2-writable.js
+++ b/tests/node_compat/test/parallel/test-stream2-writable.js
@@ -201,7 +201,8 @@ for (let i = 0; i < chunks.length; i++) {
{
// Verify write callbacks
const callbacks = chunks.map(function(chunk, i) {
- return [i, function() {
+ return [i, function(err) {
+ assert.strictEqual(err, null);
callbacks._called[i] = chunk;
}];
}).reduce(function(set, x) {
@@ -232,7 +233,9 @@ for (let i = 0; i < chunks.length; i++) {
{
// Verify end() callback
const tw = new TestWriter();
- tw.end(common.mustCall());
+ tw.end(common.mustCall(function(err) {
+ assert.strictEqual(err, null);
+ }));
}
const helloWorldBuffer = Buffer.from('hello world');
@@ -240,7 +243,9 @@ const helloWorldBuffer = Buffer.from('hello world');
{
// Verify end() callback with chunk
const tw = new TestWriter();
- tw.end(helloWorldBuffer, common.mustCall());
+ tw.end(helloWorldBuffer, common.mustCall(function(err) {
+ assert.strictEqual(err, null);
+ }));
}
{