[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: ERT / find-function type integration typos
From: |
Eshel Yaron |
Subject: |
Re: ERT / find-function type integration typos |
Date: |
Thu, 16 Jan 2025 16:53:47 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) |
Hi,
Stephen Gildea <stepheng+emacs@gildea.com> writes:
> There appears to be some confusion in both find-func.el and
> ert.el as to what "type" and regexp to use when searching for
> a test defined with 'ert-deftest'. This confusion is masked
> by find-function-search-for-symbol doing some clever fallback
> searching.
>
> In various places, both "ert-deftest" and "ert--test" are used
> as the object type. The type must match the symbol property
> used (for symbol-file), so "ert--test" is the correct type.
> I have fixed uses of "ert-deftest".
>
> This patch also fixes a problem where the button created by
> ert-describe-test passes nil as the type. Again, this error
> is masked by find-function-search-for-symbol using a fallback
> search.
>
> This look right to people?
[...]
> -(defcustom find-ert-deftest-regexp
> - "(ert-deftest +'%s"
> - "The regexp used to search for an `ert-deftest' definition.
> -Note it must contain a `%s' at the place where `format'
> -should insert the feature name."
> - :type 'regexp
> - :group 'xref
> - :version "29.1")
We may want to keep this option, and maybe even use it instead of
ert--find-test-regexp, just in case somebody decided to customize it.
Otherwise I think it looks pretty good, thanks for looking into this!
Eshel