1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 17:37:34 +00:00

LibJS: Add spec comments and check for edge cases in Math.atanh

This commit is contained in:
davidot 2022-11-28 12:02:45 +01:00 committed by Andreas Kling
parent 68aeeea5d2
commit c565cbd30c
2 changed files with 22 additions and 3 deletions

View file

@ -7,4 +7,6 @@ test("basic functionality", () => {
expect(Math.atanh(0)).toBe(0);
expect(Math.atanh(0.5)).toBeCloseTo(0.549306);
expect(Math.atanh(1)).toBe(Infinity);
expect(Math.atanh(NaN)).toBe(NaN);
expect(Math.atanh(-0.0)).toBe(-0.0);
});