diff options
Diffstat (limited to 'include/test/test.h')
-rw-r--r-- | include/test/test.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/test/test.h b/include/test/test.h index 3bbd77c38b..4ad74614af 100644 --- a/include/test/test.h +++ b/include/test/test.h @@ -13,6 +13,7 @@ * struct unit_test_state - Entire state of test system * * @fail_count: Number of tests that failed + * @skip_count: Number of tests that were skipped * @start: Store the starting mallinfo when doing leak test * @of_live: true to use livetree if available, false to use flattree * @of_root: Record of the livetree root node (used for setting up tests) @@ -27,11 +28,13 @@ * @other_fdt_size: Size of the other FDT (UT_TESTF_OTHER_FDT) * @of_other: Live tree for the other FDT * @runs_per_test: Number of times to run each test (typically 1) + * @force_run: true to run tests marked with the UT_TESTF_MANUAL flag * @expect_str: Temporary string used to hold expected string value * @actual_str: Temporary string used to hold actual string value */ struct unit_test_state { int fail_count; + int skip_count; struct mallinfo start; struct device_node *of_root; bool of_live; @@ -46,6 +49,7 @@ struct unit_test_state { int other_fdt_size; struct device_node *of_other; int runs_per_test; + bool force_run; char expect_str[512]; char actual_str[512]; }; @@ -61,6 +65,12 @@ enum { /* do extra driver model init and uninit */ UT_TESTF_DM = BIT(6), UT_TESTF_OTHER_FDT = BIT(7), /* read in other device tree */ + /* + * Only run if explicitly requested with 'ut -f <suite> <test>'. The + * test name must end in "_norun" so that pytest detects this also, + * since it cannot access the flags. + */ + UT_TESTF_MANUAL = BIT(8), }; /** |