Tom Rini | 83d290c | 2018-05-06 17:58:06 -0400 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0 */ |
Joe Hershberger | c617ede | 2015-05-20 14:27:28 -0500 | [diff] [blame] | 2 | /* |
| 3 | * (C) Copyright 2015 |
| 4 | * Joe Hershberger, National Instruments, joe.hershberger@ni.com |
Joe Hershberger | c617ede | 2015-05-20 14:27:28 -0500 | [diff] [blame] | 5 | */ |
| 6 | |
| 7 | #ifndef __TEST_SUITES_H__ |
| 8 | #define __TEST_SUITES_H__ |
| 9 | |
Simon Glass | 4d869c1 | 2017-11-25 11:57:29 -0700 | [diff] [blame] | 10 | struct unit_test; |
| 11 | |
| 12 | /** |
| 13 | * cmd_ut_category() - Run a category of unit tests |
| 14 | * |
| 15 | * @name: Category name |
Philippe Reynes | 4ad4edf | 2019-12-17 19:07:04 +0100 | [diff] [blame] | 16 | * @prefix: Prefix of test name |
Simon Glass | 4d869c1 | 2017-11-25 11:57:29 -0700 | [diff] [blame] | 17 | * @tests: List of tests to run |
| 18 | * @n_ents: Number of tests in @tests |
Heinrich Schuchardt | 4b0a2d3 | 2018-08-27 22:04:10 +0200 | [diff] [blame] | 19 | * @argc: Argument count provided. Must be >= 1. If this is 1 then all |
Simon Glass | 4d869c1 | 2017-11-25 11:57:29 -0700 | [diff] [blame] | 20 | * tests are run, otherwise only the one named @argv[1] is run. |
| 21 | * @argv: Arguments: argv[1] is the test to run (if @argc >= 2) |
| 22 | * @return 0 if OK, CMD_RET_FAILURE on failure |
| 23 | */ |
Philippe Reynes | 4ad4edf | 2019-12-17 19:07:04 +0100 | [diff] [blame] | 24 | int cmd_ut_category(const char *name, const char *prefix, |
| 25 | struct unit_test *tests, int n_ents, |
Simon Glass | 4d869c1 | 2017-11-25 11:57:29 -0700 | [diff] [blame] | 26 | int argc, char * const argv[]); |
| 27 | |
Simon Glass | 919e7a8 | 2018-11-15 18:43:53 -0700 | [diff] [blame] | 28 | int do_ut_bloblist(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]); |
Heinrich Schuchardt | f11a164 | 2018-08-31 21:31:28 +0200 | [diff] [blame] | 29 | int do_ut_compression(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]); |
Joe Hershberger | 40441e0 | 2015-05-20 14:27:29 -0500 | [diff] [blame] | 30 | int do_ut_dm(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]); |
Joe Hershberger | 421f86f | 2015-05-20 14:27:36 -0500 | [diff] [blame] | 31 | int do_ut_env(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]); |
Heinrich Schuchardt | 2dd0111 | 2019-01-30 07:53:31 +0100 | [diff] [blame] | 32 | int do_ut_lib(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]); |
Heinrich Schuchardt | 395041b | 2020-02-26 21:48:18 +0100 | [diff] [blame] | 33 | int do_ut_log(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]); |
Heiko Stuebner | 96383bd | 2019-10-23 16:46:41 +0200 | [diff] [blame] | 34 | int do_ut_optee(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]); |
Maxime Ripard | f2a9942 | 2016-07-05 10:26:46 +0200 | [diff] [blame] | 35 | int do_ut_overlay(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]); |
Joe Hershberger | c812f72 | 2015-05-20 14:27:30 -0500 | [diff] [blame] | 36 | int do_ut_time(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]); |
Heinrich Schuchardt | f11a164 | 2018-08-31 21:31:28 +0200 | [diff] [blame] | 37 | int do_ut_unicode(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]); |
Joe Hershberger | 40441e0 | 2015-05-20 14:27:29 -0500 | [diff] [blame] | 38 | |
Joe Hershberger | c617ede | 2015-05-20 14:27:28 -0500 | [diff] [blame] | 39 | #endif /* __TEST_SUITES_H__ */ |