]> git.eshelyaron.com Git - emacs.git/commitdiff
Add doc string to time-stamp-tests that didn't have one
authorStephen Gildea <stepheng+emacs@gildea.com>
Sun, 18 Jul 2021 15:38:37 +0000 (08:38 -0700)
committerStephen Gildea <stepheng+emacs@gildea.com>
Sun, 18 Jul 2021 15:44:18 +0000 (08:44 -0700)
* test/lisp/time-stamp-tests.el (formatz-generate-tests,
  formatz-%z-spotcheck): Add doc strings to tests.

test/lisp/time-stamp-tests.el

index e42a58a168540c94d79dad1dd1ec4f5419f1af88..0d64320496dc26fddf7a46822fb503150fc20538 100644 (file)
@@ -904,17 +904,23 @@ the other expected results for hours greater than 99 with non-zero seconds."
        ert-test-list
        (list
         `(ert-deftest ,(intern (concat "formatz-" form-string "-hhmm")) ()
+           ,(concat "Tests time-stamp format " form-string
+                   " with whole hours or minutes.")
            (should (equal (formatz ,form-string (fz-make+zone 0))
                           ,(car hour-mod)))
            (formatz-hours-exact-helper ,form-string ',(cdr hour-mod))
            (should (equal (formatz ,form-string (fz-make+zone 0 30))
                           ,(car mins-mod)))
            (formatz-nonzero-minutes-helper ,form-string ',(cdr mins-mod)))
-        `(ert-deftest ,(intern (concat "formatz-" form-string "-secs")) ()
+        `(ert-deftest ,(intern (concat "formatz-" form-string "-seconds")) ()
+           ,(concat "Tests time-stamp format " form-string
+                   " with offsets that have non-zero seconds.")
            (should (equal (formatz ,form-string (fz-make+zone 0 0 30))
                           ,(car secs-mod)))
            (formatz-nonzero-seconds-helper ,form-string ',(cdr secs-mod)))
-        `(ert-deftest ,(intern (concat "formatz-" form-string "-big")) ()
+        `(ert-deftest ,(intern (concat "formatz-" form-string "-threedigit")) ()
+           ,(concat "Tests time-stamp format " form-string
+                   " with offsets that are 100 hours or greater.")
            (should (equal (formatz ,form-string (fz-make+zone 100))
                           ,(car big-mod)))
            (formatz-hours-big-helper ,form-string ',(cdr big-mod))
@@ -954,6 +960,7 @@ the other expected results for hours greater than 99 with non-zero seconds."
 ;; The legacy exception for %z in time-stamp will need to remain
 ;; through at least 2024 and Emacs 28.
 (ert-deftest formatz-%z-spotcheck ()
+  "Spot-checks internal implementation of time-stamp format %z."
   (should (equal (format-time-offset "%z" (fz-make+zone 0)) "+0000"))
   (should (equal (format-time-offset "%z" (fz-make+zone 0 30)) "+0030"))
   (should (equal (format-time-offset "%z" (fz-make+zone 0 0 30)) "+000030"))