Re: [PATCH] selftests: harness: Restore order of test functions

From: Kees Cook

Date: Mon Apr 20 2026 - 18:03:58 EST


On Mon, Apr 20, 2026 at 10:44:04AM +0200, Thomas Weißschuh (Schneider Electric) wrote:
> The recent addition of explicit constructor orders for fixture tests
> broke the ordering of those relative to non-fixture tests and the
> reverse-constructor-order detection.
>
> Restore the ordering of the test functions relative to each other by
> using the same explicit test order for all test registrations and
> __constructor_order_first().
>
> Rename the constant, as it is not specific to TEST_F() anymore.
>
> Fixes: 6be268151426 ("selftests/harness: order TEST_F and XFAIL_ADD constructors")
> Signed-off-by: Thomas Weißschuh <thomas.weissschuh@xxxxxxxxxxxxx>

Ah, good catch!

Reviewed-by: Kees Cook <kees@xxxxxxxxxx>

-Kees

--
Kees Cook