Commit 855b3e70 authored by Glenn Morris's avatar Glenn Morris
Browse files

Avoid subr test failure when source dir has multiple names

* test/lisp/subr-tests.el (subr-tests--this-file):
Use the true name of the file.  The following test does a string
comparison of this value with that from method-files, which uses
load-history, which contains true names.
parent e3b51b08
...@@ -298,7 +298,8 @@ cf. Bug#25477." ...@@ -298,7 +298,8 @@ cf. Bug#25477."
(cl-defmethod subr-tests--generic ((x integer)) (cl-defmethod subr-tests--generic ((x integer))
(message "%s is a number" x)) (message "%s is a number" x))
(cl-defgeneric subr-tests--generic-without-methods (x y)) (cl-defgeneric subr-tests--generic-without-methods (x y))
(defvar subr-tests--this-file (or load-file-name buffer-file-name)) (defvar subr-tests--this-file
(file-truename (or load-file-name buffer-file-name)))
(ert-deftest subr-tests--method-files--finds-methods () (ert-deftest subr-tests--method-files--finds-methods ()
"`method-files' returns a list of files and methods for a generic function." "`method-files' returns a list of files and methods for a generic function."
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment