diff options
author | Sean Allred <code@seanallred.com> | 2015-01-01 16:57:49 -0500 |
---|---|---|
committer | Sean Allred <code@seanallred.com> | 2015-01-01 16:57:49 -0500 |
commit | 7da9b2567c2635dfab5f9400fb76297f61b80be4 (patch) | |
tree | 8e3cf546276fdd41b9919c3585121616bb021256 | |
parent | 7d73bc8b9da4a093b0a3b477da81252d5b805ca5 (diff) |
Test sx-time-since
-rw-r--r-- | test/test-printing.el | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/test/test-printing.el b/test/test-printing.el index 6225bf6..60382b2 100644 --- a/test/test-printing.el +++ b/test/test-printing.el @@ -27,6 +27,18 @@ after being run through `sx-question--tag-format'." ;;; Tests +(ert-deftest time-since () + (cl-letf (((symbol-function #'float-time) + (lambda () 1420148997.))) + (should + (string= + "67m" + (sx-time-since 1420145000.))) + (should + (string= + "12h" + (sx-time-since 1420105000.))))) + (ert-deftest question-list-tag () "Test `sx-question--tag-format'." (should |