diff --git a/tests/unit-global/esnext.math.f16round.js b/tests/unit-global/esnext.math.f16round.js index 30a53fcca141..64e8d749d84f 100644 --- a/tests/unit-global/esnext.math.f16round.js +++ b/tests/unit-global/esnext.math.f16round.js @@ -32,8 +32,8 @@ QUnit.test('Math.f16round', assert => { assert.same(f16round(-minFloat16), -minFloat16); assert.same(f16round(minFloat16 / 2), 0); assert.same(f16round(-minFloat16 / 2), -0); - assert.same(f16round(minFloat16 / 2 + 2 ** -25), minFloat16); - assert.same(f16round(-minFloat16 / 2 - 2 ** -25), -minFloat16); + assert.same(f16round(2.980232238769531911744490042422139897126953655970282852649688720703125e-8), minFloat16); + assert.same(f16round(-2.980232238769531911744490042422139897126953655970282852649688720703125e-8), -minFloat16); assert.same(f16round(1.337), 1.3369140625); diff --git a/tests/unit-pure/esnext.math.f16round.js b/tests/unit-pure/esnext.math.f16round.js index b14eafd9f112..9d9062a9ee06 100644 --- a/tests/unit-pure/esnext.math.f16round.js +++ b/tests/unit-pure/esnext.math.f16round.js @@ -31,8 +31,8 @@ QUnit.test('Math.f16round', assert => { assert.same(f16round(-minFloat16), -minFloat16); assert.same(f16round(minFloat16 / 2), 0); assert.same(f16round(-minFloat16 / 2), -0); - assert.same(f16round(minFloat16 / 2 + 2 ** -25), minFloat16); - assert.same(f16round(-minFloat16 / 2 - 2 ** -25), -minFloat16); + assert.same(f16round(2.980232238769531911744490042422139897126953655970282852649688720703125e-8), minFloat16); + assert.same(f16round(-2.980232238769531911744490042422139897126953655970282852649688720703125e-8), -minFloat16); assert.same(f16round(1.337), 1.3369140625);