From b7ba2c36b96c8102115bb86d812459b9ccb96f1d Mon Sep 17 00:00:00 2001 From: wafuwafu13 Date: Sat, 24 Sep 2022 22:03:19 +0900 Subject: [PATCH] test: not validate the message, but rather the error code --- test/parallel/test-fs-read.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/test/parallel/test-fs-read.js b/test/parallel/test-fs-read.js index 294f8ce3e048c3..966185c5138d63 100644 --- a/test/parallel/test-fs-read.js +++ b/test/parallel/test-fs-read.js @@ -79,11 +79,7 @@ assert.throws( assert.throws( () => fs.read(fd, { buffer: null }, common.mustNotCall()), - { - name: 'TypeError', - message: 'The "buffer" argument must be an instance of Buffer, ' + - 'TypedArray, or DataView. Received null', - }, + { code: 'ERR_INVALID_ARG_TYPE' }, 'throws when options.buffer is null' );