Tom Rini | 10e4779 | 2018-05-06 17:58:06 -0400 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0 */ |
Joe Hershberger | 11dd7cc | 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 | 11dd7cc | 2015-05-20 14:27:28 -0500 | [diff] [blame] | 5 | */ |
| 6 | |
| 7 | #ifndef __TEST_SUITES_H__ |
| 8 | #define __TEST_SUITES_H__ |
| 9 | |
Simon Glass | ed38aef | 2020-05-10 11:40:03 -0600 | [diff] [blame] | 10 | struct cmd_tbl; |
Simon Glass | 81cbe1c | 2017-11-25 11:57:29 -0700 | [diff] [blame] | 11 | struct unit_test; |
| 12 | |
| 13 | /** |
| 14 | * cmd_ut_category() - Run a category of unit tests |
| 15 | * |
| 16 | * @name: Category name |
Philippe Reynes | 1f99f84 | 2019-12-17 19:07:04 +0100 | [diff] [blame] | 17 | * @prefix: Prefix of test name |
Simon Glass | 81cbe1c | 2017-11-25 11:57:29 -0700 | [diff] [blame] | 18 | * @tests: List of tests to run |
| 19 | * @n_ents: Number of tests in @tests |
Heinrich Schuchardt | d41a382 | 2018-08-27 22:04:10 +0200 | [diff] [blame] | 20 | * @argc: Argument count provided. Must be >= 1. If this is 1 then all |
Simon Glass | 81cbe1c | 2017-11-25 11:57:29 -0700 | [diff] [blame] | 21 | * tests are run, otherwise only the one named @argv[1] is run. |
| 22 | * @argv: Arguments: argv[1] is the test to run (if @argc >= 2) |
Heinrich Schuchardt | 47b4c02 | 2022-01-19 18:05:50 +0100 | [diff] [blame] | 23 | * Return: 0 if OK, CMD_RET_FAILURE on failure |
Simon Glass | 81cbe1c | 2017-11-25 11:57:29 -0700 | [diff] [blame] | 24 | */ |
Philippe Reynes | 1f99f84 | 2019-12-17 19:07:04 +0100 | [diff] [blame] | 25 | int cmd_ut_category(const char *name, const char *prefix, |
| 26 | struct unit_test *tests, int n_ents, |
Simon Glass | ed38aef | 2020-05-10 11:40:03 -0600 | [diff] [blame] | 27 | int argc, char *const argv[]); |
Simon Glass | 81cbe1c | 2017-11-25 11:57:29 -0700 | [diff] [blame] | 28 | |
Bin Meng | 261fc06 | 2021-02-25 17:22:35 +0800 | [diff] [blame] | 29 | int do_ut_addrmap(struct cmd_tbl *cmdtp, int flag, int argc, |
| 30 | char *const argv[]); |
Marek Vasut | 2cd173c | 2023-05-31 03:03:58 +0200 | [diff] [blame] | 31 | int do_ut_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
Simon Glass | 07a8886 | 2020-11-05 10:33:38 -0700 | [diff] [blame] | 32 | int do_ut_bootm(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
Simon Glass | b255efc | 2022-04-24 23:31:24 -0600 | [diff] [blame] | 33 | int do_ut_bootstd(struct cmd_tbl *cmdtp, int flag, int argc, |
| 34 | char *const argv[]); |
Simon Glass | ed38aef | 2020-05-10 11:40:03 -0600 | [diff] [blame] | 35 | int do_ut_bloblist(struct cmd_tbl *cmdtp, int flag, int argc, |
| 36 | char *const argv[]); |
Simon Glass | 621a97e | 2023-10-01 19:15:12 -0600 | [diff] [blame] | 37 | int do_ut_cmd(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
Steffen Jaeckel | e1788f9 | 2021-07-08 15:57:40 +0200 | [diff] [blame] | 38 | int do_ut_common(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
Simon Glass | ed38aef | 2020-05-10 11:40:03 -0600 | [diff] [blame] | 39 | int do_ut_compression(struct cmd_tbl *cmdtp, int flag, int argc, |
| 40 | char *const argv[]); |
| 41 | int do_ut_dm(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
| 42 | int do_ut_env(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
Marek Vasut | e73c611 | 2022-12-20 07:26:00 +0100 | [diff] [blame] | 43 | int do_ut_exit(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
Simon Glass | f3c6a1d | 2022-07-13 06:06:59 -0600 | [diff] [blame] | 44 | int do_ut_fdt(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
Simon Glass | 9e972c3 | 2022-10-06 08:36:16 -0600 | [diff] [blame] | 45 | int do_ut_font(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
Francis Laniel | 2dba91a | 2023-12-22 22:02:21 +0100 | [diff] [blame] | 46 | int do_ut_hush(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
Simon Glass | ed38aef | 2020-05-10 11:40:03 -0600 | [diff] [blame] | 47 | int do_ut_lib(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
Rui Miguel Silva | 433f15a | 2022-05-11 10:55:40 +0100 | [diff] [blame] | 48 | int do_ut_loadm(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
Simon Glass | ed38aef | 2020-05-10 11:40:03 -0600 | [diff] [blame] | 49 | int do_ut_log(struct cmd_tbl *cmdtp, int flag, int argc, char * const argv[]); |
Alexander Gendin | 038cb02 | 2023-10-09 01:24:36 +0000 | [diff] [blame] | 50 | int do_ut_mbr(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
Eddie James | 1a55a7a | 2023-10-24 10:43:51 -0500 | [diff] [blame] | 51 | int do_ut_measurement(struct cmd_tbl *cmdtp, int flag, int argc, char * const argv[]); |
Simon Glass | 573c0fa | 2020-07-28 19:41:14 -0600 | [diff] [blame] | 52 | int do_ut_mem(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
Simon Glass | ed38aef | 2020-05-10 11:40:03 -0600 | [diff] [blame] | 53 | int do_ut_optee(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
| 54 | int do_ut_overlay(struct cmd_tbl *cmdtp, int flag, int argc, |
| 55 | char *const argv[]); |
Stephen Carlson | e5c05ae | 2023-03-10 11:07:15 -0800 | [diff] [blame] | 56 | int do_ut_pci_mps(struct cmd_tbl *cmdtp, int flag, int argc, |
| 57 | char *const argv[]); |
Simon Glass | d242368 | 2021-05-08 06:59:58 -0600 | [diff] [blame] | 58 | int do_ut_print(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
Linus Walleij | bef3925 | 2023-02-01 00:16:13 +0100 | [diff] [blame] | 59 | int do_ut_seama(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
Simon Glass | 663a2c1 | 2020-11-01 14:15:35 -0700 | [diff] [blame] | 60 | int do_ut_setexpr(struct cmd_tbl *cmdtp, int flag, int argc, |
| 61 | char *const argv[]); |
Simon Glass | ed38aef | 2020-05-10 11:40:03 -0600 | [diff] [blame] | 62 | int do_ut_str(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
| 63 | int do_ut_time(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); |
| 64 | int do_ut_unicode(struct cmd_tbl *cmdtp, int flag, int argc, |
| 65 | char *const argv[]); |
Joe Hershberger | 9dc1d71 | 2015-05-20 14:27:29 -0500 | [diff] [blame] | 66 | |
Joe Hershberger | 11dd7cc | 2015-05-20 14:27:28 -0500 | [diff] [blame] | 67 | #endif /* __TEST_SUITES_H__ */ |