aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Monnier2019-07-02 15:11:16 -0400
committerStefan Monnier2019-07-02 15:11:16 -0400
commita2c56a90f939e9becb7bb47328e72c58eff40b5e (patch)
treebd5f0ee3bdcef286504f187930ae23918d948ce9
parent0a7bc33da7bcc8db7d96549ba0f0d500e6c41070 (diff)
downloademacs-a2c56a90f939e9becb7bb47328e72c58eff40b5e.tar.gz
emacs-a2c56a90f939e9becb7bb47328e72c58eff40b5e.zip
* test/src/editfns-tests.el (test-group-name): Accept nil group-name.
-rw-r--r--test/src/editfns-tests.el16
1 files changed, 8 insertions, 8 deletions
diff --git a/test/src/editfns-tests.el b/test/src/editfns-tests.el
index 1e8b7066d15..69cca5d2bdd 100644
--- a/test/src/editfns-tests.el
+++ b/test/src/editfns-tests.el
@@ -165,10 +165,10 @@
165 (should (string-equal (format "%d" -18446744073709551616.0) 165 (should (string-equal (format "%d" -18446744073709551616.0)
166 "-18446744073709551616"))) 166 "-18446744073709551616")))
167 167
168;;; Perhaps Emacs will be improved someday to return the correct 168;; Perhaps Emacs will be improved someday to return the correct
169;;; answer for positive numbers instead of overflowing; in 169;; answer for positive numbers instead of overflowing; in
170;;; that case these tests will need to be changed. In the meantime make 170;; that case these tests will need to be changed. In the meantime make
171;;; sure Emacs is reporting the overflow correctly. 171;; sure Emacs is reporting the overflow correctly.
172(ert-deftest format-%x-large-float () 172(ert-deftest format-%x-large-float ()
173 (should-error (format "%x" 18446744073709551616.0) 173 (should-error (format "%x" 18446744073709551616.0)
174 :type 'overflow-error)) 174 :type 'overflow-error))
@@ -351,10 +351,10 @@
351 "-0x000000003ffffffffffffffe000000000000000 ")))) 351 "-0x000000003ffffffffffffffe000000000000000 "))))
352 352
353(ert-deftest test-group-name () 353(ert-deftest test-group-name ()
354 ;; FIXME: Actually my GID in one of my systems has no associated entry 354 (let ((group-name (group-name (group-gid))))
355 ;; in /etc/group so there's no name for it and `group-name' correctly 355 ;; If the GID has no associated entry in /etc/group there's no
356 ;; returns nil! 356 ;; name for it and `group-name' should return nil!
357 (should (stringp (group-name (group-gid)))) 357 (should (or (null group-name) (stringp group-name))))
358 (should-error (group-name 'foo)) 358 (should-error (group-name 'foo))
359 (cond 359 (cond
360 ((memq system-type '(windows-nt ms-dos)) 360 ((memq system-type '(windows-nt ms-dos))