commit 59f3ed34ab7b032ce926c7b2e8f37460c1a7d619 Author: Andreas Roehler Date: Tue Mar 12 16:44:13 2013 +0100 Fix missing `case-fold-search', test-ob-emacs-lisp.el Running tests from org-mode/testing/README failed due to missing case-folding Downcased "result" was searched while upcased was inserted diff --git a/testing/lisp/test-ob-emacs-lisp.el b/testing/lisp/test-ob-emacs-lisp.el index 94092e4..ed85a6d 100644 --- a/testing/lisp/test-ob-emacs-lisp.el +++ b/testing/lisp/test-ob-emacs-lisp.el @@ -24,55 +24,58 @@ ;;; Code: (ert-deftest ob-emacs-lisp/commented-last-block-line-no-var () - (org-test-with-temp-text-in-file " + (let (case-fold-search) + (org-test-with-temp-text-in-file " #+begin_src emacs-lisp ;; #+end_src" - (org-babel-next-src-block) - (org-ctrl-c-ctrl-c) - (should (re-search-forward "results:" nil t)) - (forward-line) - (should - (string= - "" - (buffer-substring-no-properties (point-at-bol) (point-at-eol))))) - (org-test-with-temp-text-in-file " + (org-babel-next-src-block) + (org-ctrl-c-ctrl-c) + (should (re-search-forward "results:" nil t)) + (forward-line) + (should + (string= + "" + (buffer-substring-no-properties (point-at-bol) (point-at-eol))))) + (org-test-with-temp-text-in-file " #+begin_src emacs-lisp \"some text\";; #+end_src" - (org-babel-next-src-block) - (org-ctrl-c-ctrl-c) - (should (re-search-forward "results:" nil t)) - (forward-line) - (should - (string= - ": some text" - (buffer-substring-no-properties (point-at-bol) (point-at-eol)))))) + (org-babel-next-src-block) + (org-ctrl-c-ctrl-c) + (should (re-search-forward "results:" nil t)) + (forward-line) + (should + (string= + ": some text" + (buffer-substring-no-properties (point-at-bol) (point-at-eol))))))) (ert-deftest ob-emacs-lisp/commented-last-block-line-with-var () - (org-test-with-temp-text-in-file " + (let (case-fold-search) + (org-test-with-temp-text-in-file " #+begin_src emacs-lisp :var a=1 ;; #+end_src" + (org-babel-next-src-block) + (org-ctrl-c-ctrl-c) + (re-search-forward "results" nil t) + (forward-line) + (should (string= + "" + (buffer-substring-no-properties (point-at-bol) (point-at-eol)))))) + (org-test-with-temp-text-in-file " +#+begin_src emacs-lisp :var a=2 +2;; +#+end_src" (org-babel-next-src-block) (org-ctrl-c-ctrl-c) (re-search-forward "results" nil t) (forward-line) (should (string= - "" + ": 2" (buffer-substring-no-properties (point-at-bol) (point-at-eol)))))) -(org-test-with-temp-text-in-file " -#+begin_src emacs-lisp :var a=2 -2;; -#+end_src" - (org-babel-next-src-block) - (org-ctrl-c-ctrl-c) - (re-search-forward "results" nil t) - (forward-line) - (should (string= - ": 2" - (buffer-substring-no-properties (point-at-bol) (point-at-eol))))) + (provide 'test-ob-emacs-lisp) ;;; test-ob-emacs-lisp.el ends here