weston/doc/sphinx
Pekka Paalanen d47ae7351a tests: new test listing macros
This is a step towards getting rid of the __start_test_section and
__stop_test_section usage. The old macros assumed that all individual
variables assigned to the test section would be packed there as if in an
array. Mostly this seemed to work, too, with some magical alignment
fixes in the past. It was not guaranteed to work.

With the new test listing macros, we collect an actual array. The
drawback is that we need to mention all the test entry points explicitly
and they look like normal functions in the code - which they now are.
Their argument typing is safe, and their arguments are explicitly
visible. We rely on the compiler to complain about unused functions if
any entry point is forgotten from the array.

The array is still put into the test section, because this seems to be
the only feasible way of letting the harness code support both the old
and new test listing macros at the same time. This allows converting
each test program individually.

TESTFN_ARG() needs an explicit cast on the function pointer type,
because the data argument pointer type will not match const void*.

As an example of using the new macros, linalg-test.c is converted.

Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
2026-05-28 16:29:56 +03:00
..
toc tests: new test listing macros 2026-05-28 16:29:56 +03:00
conf.py.in doc/sphinx/conf.py.in: Change sphinx.ext.intersphinx 2025-05-12 20:29:01 +03:00
doxygen.ini.in doc/sphinx/doxygen.ini.in: Removed deprecated HTML timestampt option 2025-05-12 15:15:01 +03:00
index.rst doc: Fix index.rst still mentioning Weston ref compositor 2026-02-25 11:01:14 +02:00
meson.build doc: fix Meson warning about install_subdir 2025-12-16 15:19:02 +00:00
run_doxygen_sphinx.sh.in doc: fix Meson warning about install_subdir 2025-12-16 15:19:02 +00:00