On 2025-05-16 19:06:31+0000, Rae Moar wrote:
<snip>
-Alternatively, you could conditionally ``#include`` the test file at the end of -your .c file. For example:
- /* In the KUnit test file "my_file_test.c" */
- #include <kunit/visibility.h>
- #include <my_file.h>
- ...
- MODULE_IMPORT_NS(EXPORTED_FOR_KUNIT_TESTING);
This should to be MODULE_IMPORT_NS("EXPORTED_FOR_KUNIT_TESTING"). See commit cdd30ebb1b9f ("module: Convert symbol namespace to string literal")
Can this still be fixed up?
- ...
- // Use do_interesting_thing() in tests
<snip>