]>
git.ipfire.org Git - people/ms/u-boot.git/blob - include/test/test.h
2 * Copyright (c) 2013 Google, Inc.
4 * SPDX-License-Identifier: GPL-2.0+
13 * struct unit_test_state - Entire state of test system
15 * @fail_count: Number of tests that failed
16 * @start: Store the starting mallinfo when doing leak test
17 * @priv: A pointer to some other info some suites want to track
18 * @of_root: Record of the livetree root node (used for setting up tests)
20 struct unit_test_state
{
22 struct mallinfo start
;
24 struct device_node
*of_root
;
28 * struct unit_test - Information about a unit test
31 * @func: Function to call to perform test
32 * @flags: Flags indicated pre-conditions for test
37 int (*func
)(struct unit_test_state
*state
);
41 /* Declare a new unit test */
42 #define UNIT_TEST(_name, _flags, _suite) \
43 ll_entry_declare(struct unit_test, _name, _suite) = { \
51 #endif /* __TEST_TEST_H */