diff options
Diffstat (limited to 'test/parallel/test-fs-fsync.js')
-rw-r--r-- | test/parallel/test-fs-fsync.js | 27 |
1 files changed, 4 insertions, 23 deletions
diff --git a/test/parallel/test-fs-fsync.js b/test/parallel/test-fs-fsync.js index 80443662c2..ea80d4cbcd 100644 --- a/test/parallel/test-fs-fsync.js +++ b/test/parallel/test-fs-fsync.js @@ -55,7 +55,7 @@ fs.open(fileTemp, 'a', 0o777, common.mustCall(function(err, fd) { { code: 'ERR_INVALID_ARG_TYPE', type: TypeError, - message: 'The "fd" argument must be of type number' + message: 'The "fd" argument must be of type integer' } ); common.expectsError( @@ -63,7 +63,7 @@ fs.open(fileTemp, 'a', 0o777, common.mustCall(function(err, fd) { { code: 'ERR_INVALID_ARG_TYPE', type: TypeError, - message: 'The "fd" argument must be of type number' + message: 'The "fd" argument must be of type integer' } ); common.expectsError( @@ -71,7 +71,7 @@ fs.open(fileTemp, 'a', 0o777, common.mustCall(function(err, fd) { { code: 'ERR_INVALID_ARG_TYPE', type: TypeError, - message: 'The "fd" argument must be of type number' + message: 'The "fd" argument must be of type integer' } ); common.expectsError( @@ -79,26 +79,7 @@ fs.open(fileTemp, 'a', 0o777, common.mustCall(function(err, fd) { { code: 'ERR_INVALID_ARG_TYPE', type: TypeError, - message: 'The "fd" argument must be of type number' - } - ); -}); - -[-1, 0xFFFFFFFF + 1].forEach((i) => { - common.expectsError( - () => fs.fsync(i), - { - code: 'ERR_OUT_OF_RANGE', - type: RangeError, - message: 'The "fd" argument is out of range' - } - ); - common.expectsError( - () => fs.fsyncSync(i), - { - code: 'ERR_OUT_OF_RANGE', - type: RangeError, - message: 'The "fd" argument is out of range' + message: 'The "fd" argument must be of type integer' } ); }); |