Subject: Re: bug#76447: 29.4; ert-run-tests-batch now aborts if a test signals an undefined error

From: Philipp Stephani <[email-masked]>
Date: Sun, 16 Mar 2025 19:04:59 +0100

> Am 15.03.2025 um 14:57 schrieb Stefan Monnier <[email-masked]>:
> 
>>> test-2 isn't executed.  I think the Emacs 29.4 behavior is more
>>> "user-friendly", though this (signaling an error symbol that doesn't
>>> derive from 'error') is arguably a corner case.
> 
> Indeed, it really should never happen.  Similarly `ignore-errors` will
> not catch your `foo` signal.  I don't think it's a problem in ERT.
> 
> But maybe we should make `signal` signal an error if the provided
> error-symbol is not a valid error condition symbol, as in the patch below?

The manual says this about 'signal':

    The argument ERROR-SYMBOL must be an “error symbol”--a symbol
    defined with ‘define-error’.

So I guess raising an error if the 'error symbol' is not an error symbol makes sense.  It would enforce the 'must' clause.