diff options
author | Eric Schulte <schulte.eric@gmail.com> | 2011-09-26 06:16:55 -0600 |
---|---|---|
committer | Eric Schulte <schulte.eric@gmail.com> | 2011-09-26 06:16:55 -0600 |
commit | 832fd8b415d1dc56ecea3c2fb985d2b904beae45 (patch) | |
tree | ea2faa2cb40d1d32709f44f2dd232b0029d806ba | |
parent | 32cf8bf731b7d4852b1dbe8b1572206e9c6a9396 (diff) | |
download | org-mode-832fd8b415d1dc56ecea3c2fb985d2b904beae45.tar.gz |
less hacky check for executables when loading tests
* testing/org-test.el (org-test-for-executable): Less hacky check for
executables when loading tests.
-rw-r--r-- | testing/org-test.el | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/testing/org-test.el b/testing/org-test.el index 9e80844..a2285a0 100644 --- a/testing/org-test.el +++ b/testing/org-test.el @@ -107,7 +107,10 @@ org-test searches this directory up the directory tree.") This can be used at the top of code-block-language specific test files to avoid loading the file on systems without the executable." - (unless (> (length (shell-command-to-string (format "which %s" exe))) 0) + (unless (reduce + (lambda (acc dir) + (or acc (file-exists-p (expand-file-name exe dir)))) + exec-path :initial-value nil) (throw 'missing-test-dependency exe))) (defun org-test-buffer (&optional file) |