js/src/tests/ecma_6/Math/cosh-exact.js

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/js/src/tests/ecma_6/Math/cosh-exact.js	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,19 @@
     1.4 +// Properties of Math.cosh that are guaranteed by the spec.
     1.5 +
     1.6 +// If x is NaN, the result is NaN.
     1.7 +assertEq(Math.cosh(NaN), NaN);
     1.8 +
     1.9 +// If x is +0, the result is 1.
    1.10 +assertEq(Math.cosh(+0), 1);
    1.11 +
    1.12 +// If x is −0, the result is 1.
    1.13 +assertEq(Math.cosh(-0), 1);
    1.14 +
    1.15 +// If x is +∞, the result is +∞.
    1.16 +assertEq(Math.cosh(Infinity), Infinity);
    1.17 +
    1.18 +// If x is −∞, the result is +∞.
    1.19 +assertEq(Math.cosh(-Infinity), Infinity);
    1.20 +
    1.21 +
    1.22 +reportCompare(0, 0, "ok");

mercurial