isNan,
isSafeIntegralNumber,
ln,
- LN10,
ln1p,
- LN2,
log10,
- LOG10ℇ,
log2,
- LOG2ℇ,
max,
- MAXIMUM_NUMBER,
- MAXIMUM_SAFE_INTEGRAL_NUMBER,
min,
- MINIMUM_NUMBER,
- MINIMUM_SAFE_INTEGRAL_NUMBER,
- NAN,
- NEGATIVE_INFINITY,
- NEGATIVE_ZERO,
- POSITIVE_INFINITY,
- POSITIVE_ZERO,
rand,
- RECIPROCAL_SQRT2,
round,
sgn,
sin,
sinh,
sqrt,
- SQRT2,
tan,
tanh,
toBigInt,
toSignedIntegralNumeric,
toUnsignedIntegralNumeric,
trunc,
- Ε,
- Π,
- ℇ,
} from "./numeric.js";
-describe("LN10", () => {
- it("[[Get]] is ln(10)", () => {
- assertStrictEquals(LN10, Math.LN10);
- });
-});
-
-describe("LN2", () => {
- it("[[Get]] is ln(2)", () => {
- assertStrictEquals(LN2, Math.LN2);
- });
-});
-
-describe("LOG10ℇ", () => {
- it("[[Get]] is log10(ℇ)", () => {
- assertStrictEquals(LOG10ℇ, Math.LOG10E);
- });
-});
-
-describe("LOG2ℇ", () => {
- it("[[Get]] is log2(ℇ)", () => {
- assertStrictEquals(LOG2ℇ, Math.LOG2E);
- });
-});
-
-describe("MAXIMUM_NUMBER", () => {
- it("[[Get]] is the maximum number", () => {
- assertStrictEquals(MAXIMUM_NUMBER, Number.MAX_VALUE);
- });
-});
-
-describe("MAXIMUM_SAFE_INTEGRAL_NUMBER", () => {
- it("[[Get]] is the maximum safe integral number", () => {
- assertStrictEquals(
- MAXIMUM_SAFE_INTEGRAL_NUMBER,
- Number.MAX_SAFE_INTEGER,
- );
- });
-});
-
-describe("MINIMUM_NUMBER", () => {
- it("[[Get]] is the minimum number", () => {
- assertStrictEquals(MINIMUM_NUMBER, Number.MIN_VALUE);
- });
-});
-
-describe("MINIMUM_SAFE_INTEGRAL_NUMBER", () => {
- it("[[Get]] is the minimum safe integral number", () => {
- assertStrictEquals(
- MINIMUM_SAFE_INTEGRAL_NUMBER,
- Number.MIN_SAFE_INTEGER,
- );
- });
-});
-
-describe("NAN", () => {
- it("[[Get]] is nan", () => {
- assertStrictEquals(NAN, NaN);
- });
-});
-
-describe("NEGATIVE_INFINITY", () => {
- it("[[Get]] is negative infinity", () => {
- assertStrictEquals(NEGATIVE_INFINITY, -Infinity);
- });
-});
-
-describe("NEGATIVE_ZERO", () => {
- it("[[Get]] is negative zero", () => {
- assertStrictEquals(NEGATIVE_ZERO, -0);
- });
-});
-
-describe("POSITIVE_INFINITY", () => {
- it("[[Get]] is negative infinity", () => {
- assertStrictEquals(POSITIVE_INFINITY, Infinity);
- });
-});
-
-describe("POSITIVE_ZERO", () => {
- it("[[Get]] is positive zero", () => {
- assertStrictEquals(POSITIVE_ZERO, 0);
- });
-});
-
-describe("RECIPROCAL_SQRT2", () => {
- it("[[Get]] is sqrt(½)", () => {
- assertStrictEquals(RECIPROCAL_SQRT2, Math.SQRT1_2);
- });
-});
-
-describe("SQRT2", () => {
- it("[[Get]] is sqrt(2)", () => {
- assertStrictEquals(SQRT2, Math.SQRT2);
- });
-});
-
-describe("Ε", () => {
- it("[[Get]] is ε", () => {
- assertStrictEquals(Ε, Number.EPSILON);
- });
-});
-
-describe("Π", () => {
- it("[[Get]] is π", () => {
- assertStrictEquals(Π, Math.PI);
- });
-});
-
-describe("ℇ", () => {
- it("[[Get]] is ℇ", () => {
- assertStrictEquals(ℇ, Math.E);
- });
-});
-
describe("abs", () => {
it("[[Call]] returns the absolute value", () => {
assertStrictEquals(abs(-1), 1);