bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#28385: ert "should" macros to not be globally visible


From: Stefan Kangas
Subject: bug#28385: ert "should" macros to not be globally visible
Date: Mon, 10 Aug 2020 09:58:50 -0700
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

tags 28385 + wontfix notabug
close 28385
thanks

Stefan Kangas <stefan@marxist.se> writes:

> Lars Ingebrigtsen <larsi@gnus.org> writes:
>
>> Glenn Morris <rgm@gnu.org> writes:
>>
>>> Now "should", "should-not", and "should-error" are globally defined as
>>> macros (with no "ert-" prefix). They are only useful inside ert-deftests.
>>> Perhaps they should steal a trick from the similar "skip-unless", which
>>> is not globally visible. The global definition is "ert--skip-unless",
>>> and the ert-deftest macro basically makes "skip-unless" an alias for
>>> this inside the body of a test. This seems cleaner.
>>
>> When writing tests, I find it convenient that I can `C-x C-e'
>>
>>   (should ...)
>>
>> terms.  I mean, I could just `C-x C-e' the insides of the form instead,
>> but still...
>
> I agree; I do this all the time when developing tests.  C-x C-e inside
> the form doesn't help much e.g. when you have a let form doing some
> setup that contains multiple should statements.  (See
> test/lisp/bookmark-tests.el for an example.)
>
> With all due respect to Glenn, I would suggest to close this as wontfix.

No further comments within 45 weeks, so I'm closing this now.

Feel free to reopen if you disagree and we can discuss it.

Best regards,
Stefan Kangas





reply via email to

[Prev in Thread] Current Thread [Next in Thread]