diff --git a/test/parallel/test-fs-stat.js b/test/parallel/test-fs-stat.js index 00fcc1df21c586..0c3a2e8b4801c2 100644 --- a/test/parallel/test-fs-stat.js +++ b/test/parallel/test-fs-stat.js @@ -28,7 +28,7 @@ fs.open('.', 'r', undefined, common.mustCall(function(err, fd) { fs.fstat(fd, common.mustCall(function(err, stats) { assert.ifError(err); assert.ok(stats.mtime instanceof Date); - fs.close(fd); + fs.close(fd, assert.ifError); assert.strictEqual(this, global); })); @@ -47,7 +47,7 @@ fs.open('.', 'r', undefined, common.mustCall(function(err, fd) { console.dir(stats); assert.ok(stats.mtime instanceof Date); } - fs.close(fd); + fs.close(fd, assert.ifError); })); console.log(`stating: ${__filename}`);