diff options
author | Jim Porter <jporterbugs@gmail.com> | 2022-08-14 13:44:04 -0700 |
---|---|---|
committer | Jim Porter <jporterbugs@gmail.com> | 2022-08-15 20:40:27 -0700 |
commit | c1f1be4b73072440518f02356998cf58ba127ebd (patch) | |
tree | c56338d1c699bb6ca1cbdf39a13fd939f9d0ff3a /test/lisp/eshell/em-basic-tests.el | |
parent | 07b8fb197a3057a3419be0335236547e4d7a326b (diff) | |
download | emacs-c1f1be4b73072440518f02356998cf58ba127ebd.tar.gz emacs-c1f1be4b73072440518f02356998cf58ba127ebd.tar.bz2 emacs-c1f1be4b73072440518f02356998cf58ba127ebd.zip |
Add 'eshell-command-result-equal' with an ERT explainer
* test/lisp/eshell/eshell-tests-helpers.el
(eshell-command-result--equal, eshell-command-result--equal-explainer)
(eshell-command-result-equal): New functions.
* test/lisp/eshell/em-basic-tests.el
* test/lisp/eshell/em-dirs-tests.el
* test/lisp/eshell/esh-cmd-tests.el
* test/lisp/eshell/esh-proc-tests.el
* test/lisp/eshell/esh-var-tests.el
* test/lisp/eshell/eshell-tests.el: Use 'eshell-command-result-equal'.
Diffstat (limited to 'test/lisp/eshell/em-basic-tests.el')
-rw-r--r-- | test/lisp/eshell/em-basic-tests.el | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/test/lisp/eshell/em-basic-tests.el b/test/lisp/eshell/em-basic-tests.el index 7a24f8b46c3..bc8baeaa035 100644 --- a/test/lisp/eshell/em-basic-tests.el +++ b/test/lisp/eshell/em-basic-tests.el @@ -36,25 +36,25 @@ (ert-deftest em-basic-test/umask-print-numeric () "Test printing umask numerically." (cl-letf (((symbol-function 'default-file-modes) (lambda () #o775))) - (should (equal (eshell-test-command-result "umask") "002\n"))) + (eshell-command-result-equal "umask" "002\n")) (cl-letf (((symbol-function 'default-file-modes) (lambda () #o654))) - (should (equal (eshell-test-command-result "umask") "123\n"))) + (eshell-command-result-equal "umask" "123\n")) ;; Make sure larger numbers don't cause problems. (cl-letf (((symbol-function 'default-file-modes) (lambda () #o1775))) - (should (equal (eshell-test-command-result "umask") "002\n")))) + (eshell-command-result-equal "umask" "002\n"))) (ert-deftest em-basic-test/umask-read-symbolic () "Test printing umask symbolically." (cl-letf (((symbol-function 'default-file-modes) (lambda () #o775))) - (should (equal (eshell-test-command-result "umask -S") - "u=rwx,g=rwx,o=rx\n"))) + (eshell-command-result-equal "umask -S" + "u=rwx,g=rwx,o=rx\n")) (cl-letf (((symbol-function 'default-file-modes) (lambda () #o654))) - (should (equal (eshell-test-command-result "umask -S") - "u=wx,g=rx,o=x\n"))) + (eshell-command-result-equal "umask -S" + "u=wx,g=rx,o=x\n")) ;; Make sure larger numbers don't cause problems. (cl-letf (((symbol-function 'default-file-modes) (lambda () #o1775))) - (should (equal (eshell-test-command-result "umask -S") - "u=rwx,g=rwx,o=rx\n")))) + (eshell-command-result-equal "umask -S" + "u=rwx,g=rwx,o=rx\n"))) (ert-deftest em-basic-test/umask-set () "Test setting umask." |