diff options
Diffstat (limited to '')
| -rw-r--r-- | modules/mod-test/test.el | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/modules/mod-test/test.el b/modules/mod-test/test.el index ad4cc49c690..c1defae9bd7 100644 --- a/modules/mod-test/test.el +++ b/modules/mod-test/test.el | |||
| @@ -34,11 +34,9 @@ | |||
| 34 | (should (stringp (nth 1 descr))) | 34 | (should (stringp (nth 1 descr))) |
| 35 | (should (eq 0 | 35 | (should (eq 0 |
| 36 | (string-match | 36 | (string-match |
| 37 | (if (eq system-type 'windows-nt) | 37 | (concat "#<module function " |
| 38 | "#<module function at \\(0x\\)?[0-9a-fA-F]+ from .*>" | 38 | "\\(at \\(0x\\)?[0-9a-fA-F]+\\( from .*\\)?" |
| 39 | (if (eq system-type 'cygwin) | 39 | "\\|Fmod_test_sum from .*\\)>") |
| 40 | "#<module function at \\(0x\\)?[0-9a-fA-F]+>" | ||
| 41 | "#<module function Fmod_test_sum from .*>")) | ||
| 42 | (nth 1 descr)))) | 40 | (nth 1 descr)))) |
| 43 | (should (= (nth 2 descr) 3))) | 41 | (should (= (nth 2 descr) 3))) |
| 44 | (should-error (mod-test-sum "1" 2) :type 'wrong-type-argument) | 42 | (should-error (mod-test-sum "1" 2) :type 'wrong-type-argument) |
| @@ -48,10 +46,10 @@ | |||
| 48 | (1- most-positive-fixnum))) | 46 | (1- most-positive-fixnum))) |
| 49 | (should (= (mod-test-sum 1 most-negative-fixnum) | 47 | (should (= (mod-test-sum 1 most-negative-fixnum) |
| 50 | (1+ most-negative-fixnum))) | 48 | (1+ most-negative-fixnum))) |
| 51 | (should (= (mod-test-sum 1 #x1fffffff) | 49 | (should-error (mod-test-sum 1 most-positive-fixnum) |
| 52 | (1+ #x1fffffff))) | 50 | :type 'overflow-error) |
| 53 | (should (= (mod-test-sum -1 #x20000000) | 51 | (should-error (mod-test-sum -1 most-negative-fixnum) |
| 54 | #x1fffffff))) | 52 | :type 'overflow-error)) |
| 55 | 53 | ||
| 56 | (ert-deftest mod-test-sum-docstring () | 54 | (ert-deftest mod-test-sum-docstring () |
| 57 | (should (string= (documentation 'mod-test-sum) "Return A + B"))) | 55 | (should (string= (documentation 'mod-test-sum) "Return A + B"))) |