Skip to content

Commit 81e2eac

Browse files
mhdawsonGabriel Schulhof
authored andcommitted
test: update BigInt test for recent change in core
nodejs/node@689ab46 changed the expected error for one of the BigInt test cases. This is ok because BigInt is still in experimental. However, the result was a failed/hanging test. See nodejs/build#2131 This changes the test to accept either the new or old behaviour. We need that so that older versions of Node.js will also pass the test until the the node core commit above is backported. PR-URL: #649 Reviewed-By: Gabriel Schulhof <[email protected]> Reviewed-By: Nicola Del Gobbo <[email protected]>
1 parent 204f072 commit 81e2eac

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/bigint.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ function test(binding) {
4646
});
4747

4848
assert.throws(TestTooBigBigInt, {
49-
name: 'RangeError',
50-
message: 'Maximum BigInt size exceeded',
49+
name: /^(RangeError|Error)$/,
50+
message: /^(Maximum BigInt size exceeded|Invalid argument)$/,
5151
});
5252
}

0 commit comments

Comments
 (0)