* test/automated/eshell.el (eshell-test/for-name-shadow-loop):

Test value before and after loop as well as during.
This commit is contained in:
Glenn Morris 2013-09-16 14:42:41 -04:00
parent 70568a90a1
commit cde40d2bb8
2 changed files with 8 additions and 1 deletions

View file

@ -1,3 +1,8 @@
2013-09-16 Glenn Morris <rgm@gnu.org>
* automated/eshell.el (eshell-test/for-name-shadow-loop):
Test value before and after loop as well as during.
2013-09-15 Glenn Morris <rgm@gnu.org>
* automated/eshell.el (eshell-test/for-name-shadow-loop):

View file

@ -89,8 +89,10 @@
(ert-deftest eshell-test/for-name-shadow-loop () ; bug#15372
"Test `eshell-command-result' with a for loop using an env-var."
(let ((process-environment (cons "name=env-value" process-environment)))
(should (equal (eshell-test-command-result "echo $name") "env-value"))
(should (equal (eshell-test-command-result
"for name in 3 { echo $name }") 3))))
"for name in 3 { echo $name }") 3))
(should (equal (eshell-test-command-result "echo $name") "env-value"))))
(ert-deftest eshell-test/lisp-command-args ()
"Test `eshell-command-result' with elisp and trailing args.