aboutsummaryrefslogtreecommitdiffstats
path: root/test/src/data-tests.el
diff options
context:
space:
mode:
Diffstat (limited to 'test/src/data-tests.el')
-rw-r--r--test/src/data-tests.el7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/src/data-tests.el b/test/src/data-tests.el
index a9d48e29a8a..3a7462b6ada 100644
--- a/test/src/data-tests.el
+++ b/test/src/data-tests.el
@@ -653,6 +653,13 @@ comparing the subr with a much slower lisp implementation."
653 (data-tests-check-sign (% -1 -3) (% nb1 nb3)) 653 (data-tests-check-sign (% -1 -3) (% nb1 nb3))
654 (data-tests-check-sign (mod -1 -3) (mod nb1 nb3)))) 654 (data-tests-check-sign (mod -1 -3) (mod nb1 nb3))))
655 655
656(ert-deftest data-tests-mod-0 ()
657 (dolist (num (list (1- most-negative-fixnum) -1 0 1
658 (1+ most-positive-fixnum)))
659 (should-error (mod num 0)))
660 (when (ignore-errors (/ 0.0 0))
661 (should (equal (abs (mod 0.0 0)) (abs (- 0.0 (/ 0.0 0)))))))
662
656(ert-deftest data-tests-ash-lsh () 663(ert-deftest data-tests-ash-lsh ()
657 (should (= (ash most-negative-fixnum 1) 664 (should (= (ash most-negative-fixnum 1)
658 (* most-negative-fixnum 2))) 665 (* most-negative-fixnum 2)))