Subject: Re: bug#66782: 29.1; ERT tests report test redefined depending on loading sequence

From: Xiyue Deng <[email-masked]>
Date: Fri, 03 Nov 2023 10:56:00 -0700

Mattias Engdegård <[email-masked]> writes:

> 2 nov. 2023 kl. 23.00 skrev Xiyue Deng <[email-masked]>:
>
>> 1) Tests that are different but use the same test name.
>> 
>> 2) There is no tests sharing the same name, but caused by double loading
>> the same test unit through a dependency by require.
>> 
>> Case 1 happens a lot in the wild and has caused many FTBFS bugs in
>> Debian after upgrading Emacs to 29.1 (e.g. [1][2]), and the fix is
>> simply to rename the tests.
>
> Thank you, I'm happy to hear that the check actually caught the kind of errors it was supposed to find.
>
>> As a matter of fact I've spent a non-trivial time
>> trying to debug this one as it depends on the loading sequence which
>> caused the failure to be flaky.  So I hope my proposed change can help
>> people on realizing that it's case 2 a bit faster.
>
> That's fine, adding something like what you suggested doesn't cost us anything: now done on master (425d23fbea).
>
> I'm closing the bug now, but do say if there is something I forgot.
>

Thanks Mattias!  Would be better if this can be applied to 29 branch as
well now that 29.2 is around the corner :-)

-- 
Xiyue Deng