From ba891c753c5475460ec8a0ed53973e158df93ca0 Mon Sep 17 00:00:00 2001 From: Yusuke Suzuki Date: Tue, 3 Oct 2017 20:22:03 +0200 Subject: Do not use BigInt literal without `features: [BigInt]` (#1253) typeCoercion.js is included in several tests which are not marked as `features: [BigInt]`. Since BigInt is new feature, we should not make the above unrelated tests failed due to lack of BigInt syntax support. Close #1252. --- harness/typeCoercion.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'harness') diff --git a/harness/typeCoercion.js b/harness/typeCoercion.js index 76d366d76..3950d4b2c 100644 --- a/harness/typeCoercion.js +++ b/harness/typeCoercion.js @@ -330,8 +330,8 @@ function testCoercibleToBigIntZero(test) { testPrimitiveWrappers(value, "number", test); } - testCoercibleToBigIntFromBigInt(0n, test); - testPrimitiveValue(-0n); + testCoercibleToBigIntFromBigInt(BigInt(0), test); + testPrimitiveValue(-BigInt(0)); testPrimitiveValue("-0"); testPrimitiveValue(false); testPrimitiveValue(""); @@ -351,7 +351,7 @@ function testCoercibleToBigIntOne(test) { testPrimitiveWrappers(value, "number", test); } - testCoercibleToBigIntFromBigInt(1n, test); + testCoercibleToBigIntFromBigInt(BigInt(1), test); testPrimitiveValue(true); // toString() returns "1" -- cgit v1.2.1