Rather than having an init function and then running the tests, create a
test-init function to do it. This will allow us to get rid of the
command function.
Signed-off-by: Simon Glass <sjg@chromium.org>
/* Declare a new FDT-overlay test */
#define FDT_OVERLAY_TEST(_name, _flags) UNIT_TEST(_name, _flags, fdt_overlay)
+/* Declare init for FDT-overlay test */
+#define FDT_OVERLAY_TEST_INIT(_name, _flags) \
+ UNIT_TEST_INIT(_name, _flags, fdt_overlay)
+
#endif /* __TEST_OVERLAY_H__ */
return 0;
}
+FDT_OVERLAY_TEST_INIT(fdt_overlay_init, 0);
static int fdt_getprop_str(void *fdt, const char *path, const char *name,
const char **out)
const int n_ents = UNIT_TEST_SUITE_COUNT(fdt_overlay);
int ret = -ENOMEM;
- ut_assertok(fdt_overlay_init(uts));
ret = cmd_ut_category(uts, "fdt_overlay", "fdt_overlay_test_", tests,
n_ents, argc, argv);