Skip to content

Commit 9c62ea8

Browse files
author
wafuwafu13
committed
test: not validate the message, but rather the error code
1 parent b1b8d3f commit 9c62ea8

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

test/parallel/test-fs-read.js

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -79,11 +79,7 @@ assert.throws(
7979

8080
assert.throws(
8181
() => fs.read(fd, { buffer: null }, common.mustNotCall()),
82-
{
83-
name: 'TypeError',
84-
message: 'The "buffer" argument must be an instance of Buffer, ' +
85-
'TypedArray, or DataView. Received null',
86-
},
82+
{ code: 'ERR_INVALID_ARG_TYPE' },
8783
'throws when options.buffer is null'
8884
);
8985

0 commit comments

Comments
 (0)