TEST_SIGNAL(9)
π¦ TEST_SIGNAL(9) β Kernel API Manual, but make it group-chat β¨
Okay bestie, welcome to the TEST_SIGNAL(9) page from the Kernel API Manual. It's giving tiny macro, huge selftest energy, and we're gonna walk through it with zero skips. π
β¨ NAME β¨
TEST_SIGNALβ that's the name, and the original page literally just hasTEST_SIGNAL -with no description after the dash. Not me inventing lore that isn't there. π«Ά
π«Ά SYNOPSIS π«Ά
TEST_SIGNAL (test_name , signal );
π ARGUMENTS π
test_nameβ test name.signalβ signal number.
π DESCRIPTION π
The shape of it is:
TEST_SIGNAL(name, signal) { implementation }
So basically TEST_SIGNAL(name, signal) defines a test by name and the expected term signal. Slay.
β οΈ Names must be unique, and tests must not be run in parallel. That's not a vibe suggestion, bestie, it's the rule.
The implementation containing block is a function, and scoping should be treated as such. Returning early may be performed with a bare return; statement. So yes, you can dip out early with just return;.
EXPECT_* and ASSERT_* are valid in a TEST { } context. Periodt.
π SEE ALSO π
The extended universe is linked here in the exact original order, no skips: Kernel file ./tools/testing/selftests/kselftest_harness.h example(9), TH_LOG(9), SKIP(9), TEST(9), FIXTURE_DATA(9), FIXTURE(9), FIXTURE_SETUP(9), FIXTURE_TEARDOWN(9), FIXTURE_TEARDOWN_PARENT(9), FIXTURE_VARIANT(9), FIXTURE_VARIANT_ADD(9), TEST_F(9), TEST_HARNESS_MAIN(9), operators(9), ASSERT_EQ(9), ASSERT_NE(9), ASSERT_LT(9), ASSERT_LE(9), ASSERT_GT(9), ASSERT_GE(9), ASSERT_NULL(9), ASSERT_TRUE(9), ASSERT_FALSE(9), ASSERT_STREQ(9), ASSERT_STRNE(9), EXPECT_EQ(9), EXPECT_NE(9), EXPECT_LT(9), EXPECT_LE(9), EXPECT_GT(9), EXPECT_GE(9), EXPECT_NULL(9), EXPECT_TRUE(9), EXPECT_FALSE(9), EXPECT_STREQ(9), EXPECT_STRNE(9), XFAIL_ADD(9).
Mwah π β this page's source/version is ./tools/testing/selftests, dated October 2026, and it's still TEST_SIGNAL(9) at heart. π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms