kunit_test_suites(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– kunit_test_suites(9) β€” Kernel API Manual πŸ’–

✨ NAME ✨

Okay bestie, kunit_test_suites is literally the function used to register one or more &struct kunit_suite with KUnit. That’s the whole job. Iconic behavior. πŸŽ€


πŸ¦‹ SYNOPSIS πŸ¦‹

kunit_test_suites (__suites... );

🌸 ARGUMENTS 🌸

  • __suites β€” a statically allocated list of struct kunit_suite. Yes, statically allocated. Keep that energy. ✨

πŸ’œ DESCRIPTION πŸ’œ

So it registers suites with the test framework. The way this happens is by placing the array of struct kunit_suite * in the .kunit_test_suites ELF section. Very demure, very mindful, very ELF-section-coded. πŸ’…

When builtin, KUnit tests are all run via the executor at boot. When built as a module, they run on module load. Either way, the tests are gonna do their thing β€” no cap. πŸ”₯


🌈 SEE ALSO 🌈

Kernel file ./include/kunit/test.h, plus the whole KUnit bestie squad:


Okay that’s the whole page, bestie πŸ’… β€” source/version ./include/kunit, dated October 2026, page kunit_test_suites(9). Mwah 🫢✨

πŸ“¦ where this page comes from