summaryrefslogtreecommitdiff
path: root/Libraries/LibJS/Tests/builtins/Number/Number.isInteger.js
diff options
context:
space:
mode:
Diffstat (limited to 'Libraries/LibJS/Tests/builtins/Number/Number.isInteger.js')
-rw-r--r--Libraries/LibJS/Tests/builtins/Number/Number.isInteger.js32
1 files changed, 0 insertions, 32 deletions
diff --git a/Libraries/LibJS/Tests/builtins/Number/Number.isInteger.js b/Libraries/LibJS/Tests/builtins/Number/Number.isInteger.js
deleted file mode 100644
index ff0bc9370c..0000000000
--- a/Libraries/LibJS/Tests/builtins/Number/Number.isInteger.js
+++ /dev/null
@@ -1,32 +0,0 @@
-test("basic functionality", () => {
- expect(Number.isInteger).toHaveLength(1);
-
- expect(Number.isInteger(0)).toBeTrue();
- expect(Number.isInteger(42)).toBeTrue();
- expect(Number.isInteger(-10000)).toBeTrue();
- expect(Number.isInteger(5)).toBeTrue();
- expect(Number.isInteger(5.0)).toBeTrue();
- expect(Number.isInteger(5 + 1 / 10000000000000000)).toBeTrue();
- // FIXME: values outside of i32's range should still return true
- // expect(Number.isInteger(+2147483647 + 1)).toBeTrue();
- // expect(Number.isInteger(-2147483648 - 1)).toBeTrue();
- // expect(Number.isInteger(99999999999999999999999999999999999)).toBeTrue();
-
- expect(Number.isInteger(5 + 1 / 1000000000000000)).toBeFalse();
- expect(Number.isInteger(1.23)).toBeFalse();
- expect(Number.isInteger("")).toBeFalse();
- expect(Number.isInteger("0")).toBeFalse();
- expect(Number.isInteger("42")).toBeFalse();
- expect(Number.isInteger(true)).toBeFalse();
- expect(Number.isInteger(false)).toBeFalse();
- expect(Number.isInteger(null)).toBeFalse();
- expect(Number.isInteger([])).toBeFalse();
- expect(Number.isInteger(Infinity)).toBeFalse();
- expect(Number.isInteger(-Infinity)).toBeFalse();
- expect(Number.isInteger(NaN)).toBeFalse();
- expect(Number.isInteger()).toBeFalse();
- expect(Number.isInteger(undefined)).toBeFalse();
- expect(Number.isInteger("foo")).toBeFalse();
- expect(Number.isInteger({})).toBeFalse();
- expect(Number.isInteger([1, 2, 3])).toBeFalse();
-});