0
0
Fork 1
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2024-09-18 23:10:05 +00:00
org-mode/testing/lisp/test-ob-R.el
Eric Schulte 630b9c80ca Indicate tests with missing dependencies by adding a expected failing test
* testing/lisp/test-ob-R.el (featurep): Signal missing dependencies
  with an error rather than a throw.
* testing/org-test.el (missing-test-dependency): Define the error
  signal for missing dependencies.
  (org-test-for-executable): Signal missing dependencies with an error
  rather than a throw.
  (org-test-load): Define an expected failing test for each file with
  missing dependencies.
2011-11-15 08:56:25 -07:00

31 lines
768 B
EmacsLisp

;;; test-ob-R.el --- tests for ob-R.el
;; Copyright (c) 2011 Eric Schulte
;; Authors: Eric Schulte
;; Released under the GNU General Public License version 3
;; see: http://www.gnu.org/licenses/gpl-3.0.html
(org-test-for-executable "R")
(unless (featurep 'ess)
(signal 'missing-test-dependency "ESS"))
(let ((load-path (cons (expand-file-name
".." (file-name-directory
(or load-file-name buffer-file-name)))
load-path)))
(require 'org-test)
(require 'org-test-ob-consts))
(require 'ob-R)
(ert-deftest test-ob-R/simple-session ()
(org-test-with-temp-text
"#+begin_src R :session R\n paste(\"Yep!\")\n#+end_src\n"
(should (string= "Yep!" (org-babel-execute-src-block)))))
(provide 'test-ob-R)
;;; test-ob-R.el ends here