From 2e090da77591c1e0f59815a34e2a4059f418c776 Mon Sep 17 00:00:00 2001 From: Philipp Stephani Date: Sun, 25 Oct 2020 10:59:11 +0100 Subject: [PATCH] Revert commit 1f44a776729adf9c6468a76f8310616fde62eeaa for Flymake. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Flymake supports all Emacs versions back to 26.1, so it can’t use ‘ert-resource-file’. * test/lisp/progmodes/flymake-tests.el (flymake-tests-data-directory): Recreate. (flymake-tests--call-with-fixture): Stop using ‘ert-resource-file’. --- test/lisp/progmodes/flymake-tests.el | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/test/lisp/progmodes/flymake-tests.el b/test/lisp/progmodes/flymake-tests.el index c62a2dbde13..df72b523a9d 100644 --- a/test/lisp/progmodes/flymake-tests.el +++ b/test/lisp/progmodes/flymake-tests.el @@ -23,10 +23,17 @@ ;;; Code: (require 'ert) -(require 'ert-x) (require 'flymake) (eval-when-compile (require 'subr-x)) ; string-trim +(defvar flymake-tests-data-directory + (expand-file-name "lisp/progmodes/flymake-resources" + (or (getenv "EMACS_TEST_DIRECTORY") + (expand-file-name "../../.." + (or load-file-name + buffer-file-name)))) + "Directory containing flymake test data.") + ;; ;; @@ -56,7 +63,7 @@ "Call FN after flymake setup in FILE, using `flymake-proc`. SEVERITY-PREDICATE is used to setup `flymake-proc-diagnostic-type-pred'" - (let* ((file (ert-resource-file file)) + (let* ((file (expand-file-name file flymake-tests-data-directory)) (visiting (find-buffer-visiting file)) (buffer (or visiting (find-file-noselect file))) (process-environment (cons "LC_ALL=C" process-environment)) -- 2.39.2