diff options
author | Stephen Gildea <stepheng+emacs@gildea.com> | 2021-11-09 20:09:22 -0800 |
---|---|---|
committer | Stephen Gildea <stepheng+emacs@gildea.com> | 2021-11-09 20:11:07 -0800 |
commit | 8d81ab374da4d159cd05cd8caaaae2390829ccee (patch) | |
tree | 5d92ebdeb674223b227cc56fdd8b7a48ea5d96dd /test | |
parent | beaa7e14f39734eae845aa23b32b854338308ba1 (diff) | |
download | emacs-8d81ab374da4d159cd05cd8caaaae2390829ccee.tar.gz emacs-8d81ab374da4d159cd05cd8caaaae2390829ccee.tar.bz2 emacs-8d81ab374da4d159cd05cd8caaaae2390829ccee.zip |
time-stamp: %F is "file name" not "pathname" + other doc
* lisp/time-stamp.el (time-stamp-format): doc 'file' instead of 'path'.
* test/lisp/time-stamp-tests.el (formatz, format-time-offset):
Clarify the difference and similarity between these two test helpers.
Diffstat (limited to 'test')
-rw-r--r-- | test/lisp/time-stamp-tests.el | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/test/lisp/time-stamp-tests.el b/test/lisp/time-stamp-tests.el index fa9edcbd407..cb446eb486e 100644 --- a/test/lisp/time-stamp-tests.el +++ b/test/lisp/time-stamp-tests.el @@ -704,9 +704,10 @@ ;;;; Setup for tests of time offset formatting with %z (defun formatz (format zone) - "Uses time FORMAT string to format the offset of ZONE, returning the result. -FORMAT is \"%z\" or a variation. -ZONE is as the ZONE argument of the `format-time-string' function." + "Uses FORMAT to format the offset of ZONE, returning the result. +FORMAT must be time format \"%z\" or some variation thereof. +ZONE is as the ZONE argument of the `format-time-string' function. +This function is called by 99% of the `time-stamp' \"%z\" unit tests." (with-time-stamp-test-env (let ((time-stamp-time-zone zone)) ;; Call your favorite time formatter here. @@ -718,9 +719,9 @@ ZONE is as the ZONE argument of the `format-time-string' function." (defun format-time-offset (format offset-secs) "Uses FORMAT to format the time zone represented by OFFSET-SECS. -FORMAT must be \"%z\", possibly with a flag and padding. +FORMAT must be time format \"%z\" or some variation thereof. This function is a wrapper around `time-stamp-formatz-from-parsed-options' -and is used for testing." +and is called by some low-level `time-stamp' \"%z\" unit tests." ;; This wrapper adds a simple regexp-based parser that handles only ;; %z and variants. In normal use, time-stamp-formatz-from-parsed-options ;; is called from a parser that handles all time string formats. |