]> git.eshelyaron.com Git - emacs.git/commitdiff
Revert commit 1f44a776729adf9c6468a76f8310616fde62eeaa for XRef.
authorPhilipp Stephani <phst@google.com>
Sun, 25 Oct 2020 10:24:11 +0000 (11:24 +0100)
committerPhilipp Stephani <phst@google.com>
Sun, 25 Oct 2020 10:24:11 +0000 (11:24 +0100)
XRef supports Emacs versions back to Emacs 26.3, so it can’t use newer
functions such as ‘ert-resource-directory’.

* test/lisp/progmodes/xref-tests.el (xref-tests-data-dir): Don’t use
‘ert-resource-directory’

test/lisp/progmodes/xref-tests.el

index 060c9cb5d1c7b6e4ac4f9d1cf666cee1edba6df2..038f9d0e304d0df13c7c2938670ef0c3f35c5c26 100644 (file)
 ;;; Code:
 
 (require 'ert)
-(require 'ert-x)
 (require 'xref)
 (require 'cl-lib)
 
-(defvar xref-tests-data-dir (ert-resource-directory))
+(defvar xref-tests-data-dir
+  (expand-file-name "xref-resources/"
+                    (file-name-directory
+                     (or load-file-name buffer-file-name))))
 
 (ert-deftest xref-matches-in-directory-finds-none-for-some-regexp ()
   (should (null (xref-matches-in-directory "zzz" "*" xref-tests-data-dir nil))))