[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: |
Sun, 29 Sep 2019 03:26:17 +0200 |
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.
Best regards,
Stefan Kangas
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- bug#28385: ert "should" macros to not be globally visible,
Stefan Kangas <=