Lines Matching refs:test

21 static void example_simple_test(struct kunit *test)  in example_simple_test()  argument
29 KUNIT_EXPECT_EQ(test, 1 + 1, 2); in example_simple_test()
36 static int example_test_init(struct kunit *test) in example_test_init() argument
38 kunit_info(test, "initializing\n"); in example_test_init()
57 static void example_skip_test(struct kunit *test) in example_skip_test() argument
60 kunit_info(test, "You should not see a line below."); in example_skip_test()
63 kunit_skip(test, "this test should be skipped"); in example_skip_test()
66 KUNIT_FAIL(test, "You should not see this line."); in example_skip_test()
72 static void example_mark_skipped_test(struct kunit *test) in example_mark_skipped_test() argument
75 kunit_info(test, "You should see a line below."); in example_mark_skipped_test()
78 kunit_mark_skipped(test, "this test should be skipped"); in example_mark_skipped_test()
81 kunit_info(test, "You should see this line."); in example_mark_skipped_test()
87 static void example_all_expect_macros_test(struct kunit *test) in example_all_expect_macros_test() argument
90 KUNIT_EXPECT_TRUE(test, true); in example_all_expect_macros_test()
91 KUNIT_EXPECT_FALSE(test, false); in example_all_expect_macros_test()
94 KUNIT_EXPECT_EQ(test, 1, 1); /* check == */ in example_all_expect_macros_test()
95 KUNIT_EXPECT_GE(test, 1, 1); /* check >= */ in example_all_expect_macros_test()
96 KUNIT_EXPECT_LE(test, 1, 1); /* check <= */ in example_all_expect_macros_test()
97 KUNIT_EXPECT_NE(test, 1, 0); /* check != */ in example_all_expect_macros_test()
98 KUNIT_EXPECT_GT(test, 1, 0); /* check > */ in example_all_expect_macros_test()
99 KUNIT_EXPECT_LT(test, 0, 1); /* check < */ in example_all_expect_macros_test()
102 KUNIT_EXPECT_NOT_ERR_OR_NULL(test, test); in example_all_expect_macros_test()
103 KUNIT_EXPECT_PTR_EQ(test, NULL, NULL); in example_all_expect_macros_test()
104 KUNIT_EXPECT_PTR_NE(test, test, NULL); in example_all_expect_macros_test()
105 KUNIT_EXPECT_NULL(test, NULL); in example_all_expect_macros_test()
106 KUNIT_EXPECT_NOT_NULL(test, test); in example_all_expect_macros_test()
109 KUNIT_EXPECT_STREQ(test, "hi", "hi"); in example_all_expect_macros_test()
110 KUNIT_EXPECT_STRNEQ(test, "hi", "bye"); in example_all_expect_macros_test()
116 KUNIT_ASSERT_GT(test, sizeof(char), 0); in example_all_expect_macros_test()
122 KUNIT_EXPECT_GT_MSG(test, sizeof(int), 0, "Your ints are 0-bit?!"); in example_all_expect_macros_test()
123 KUNIT_ASSERT_GT_MSG(test, sizeof(int), 0, "Your ints are 0-bit?!"); in example_all_expect_macros_test()