aboutsummaryrefslogtreecommitdiffstats
path: root/test/src
diff options
context:
space:
mode:
Diffstat (limited to 'test/src')
-rw-r--r--test/src/floatfns-tests.el9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/src/floatfns-tests.el b/test/src/floatfns-tests.el
index 43a2e278290..e4caaa1e49b 100644
--- a/test/src/floatfns-tests.el
+++ b/test/src/floatfns-tests.el
@@ -42,6 +42,15 @@
42 (should (= most-positive-fixnum 42 (should (= most-positive-fixnum
43 (- (abs most-negative-fixnum) 1)))) 43 (- (abs most-negative-fixnum) 1))))
44 44
45(ert-deftest bignum-expt ()
46 (dolist (n (list most-positive-fixnum (1+ most-positive-fixnum)
47 most-negative-fixnum (1- most-negative-fixnum)
48 -2 -1 0 1 2))
49 (should (= (expt n 0) 1))
50 (should (= (expt n 1) n))
51 (should (= (expt n 2) (* n n)))
52 (should (= (expt n 3) (* n n n)))))
53
45(ert-deftest bignum-logb () 54(ert-deftest bignum-logb ()
46 (should (= (+ (logb most-positive-fixnum) 1) 55 (should (= (+ (logb most-positive-fixnum) 1)
47 (logb (+ most-positive-fixnum 1))))) 56 (logb (+ most-positive-fixnum 1)))))