Skip to content

Commit

Permalink
Fix Math.f16round unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
petamoriken committed Aug 2, 2023
1 parent cd1d1d4 commit 2689366
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions tests/unit-global/esnext.math.f16round.js
Original file line number Diff line number Diff line change
Expand Up @@ -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);

Expand Down
4 changes: 2 additions & 2 deletions tests/unit-pure/esnext.math.f16round.js
Original file line number Diff line number Diff line change
Expand Up @@ -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);

Expand Down

0 comments on commit 2689366

Please sign in to comment.