aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2023-10-01 19:15:15 -0600
committerTom Rini <trini@konsulko.com>2023-12-13 18:39:05 -0500
commit07073d2bebf22e9b260cd041222079363a000cb7 (patch)
treec565e10cb7a655586a8b8484d3b0f03bac0b3738 /test
parentf2311519caf7fcf98afccd68a8922bf6a8cea2fc (diff)
test: Run bootstd tests only on sandbox
These make use of disk images which are not available on reak boards. Add a new Kconfig to ensure these tests only run where they are valid. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'test')
-rw-r--r--test/Kconfig5
-rw-r--r--test/Makefile2
-rw-r--r--test/cmd_ut.c2
3 files changed, 7 insertions, 2 deletions
diff --git a/test/Kconfig b/test/Kconfig
index 310fb1ba6e..e842c01308 100644
--- a/test/Kconfig
+++ b/test/Kconfig
@@ -65,6 +65,11 @@ config UT_LIB_RSA
endif
+config UT_BOOTSTD
+ bool "Unit tests for standard boot"
+ depends on UNIT_TEST && SANDBOX
+ default y
+
config UT_COMPRESSION
bool "Unit test for compression"
depends on UNIT_TEST
diff --git a/test/Makefile b/test/Makefile
index 8e1fed2c28..6b8a1506f5 100644
--- a/test/Makefile
+++ b/test/Makefile
@@ -23,7 +23,7 @@ obj-$(CONFIG_UT_TIME) += time_ut.o
obj-y += ut.o
ifeq ($(CONFIG_SPL_BUILD),)
-obj-$(CONFIG_UNIT_TEST) += boot/
+obj-$(CONFIG_$(SPL_)UT_BOOTSTD) += boot/
obj-$(CONFIG_UNIT_TEST) += common/
obj-y += log/
obj-$(CONFIG_$(SPL_)UT_UNICODE) += unicode_ut.o
diff --git a/test/cmd_ut.c b/test/cmd_ut.c
index 60cd049eb9..1b934b2329 100644
--- a/test/cmd_ut.c
+++ b/test/cmd_ut.c
@@ -57,7 +57,7 @@ static struct cmd_tbl cmd_ut_sub[] = {
#ifdef CONFIG_CMD_BDI
U_BOOT_CMD_MKENT(bdinfo, CONFIG_SYS_MAXARGS, 1, do_ut_bdinfo, "", ""),
#endif
-#ifdef CONFIG_BOOTSTD
+#ifdef CONFIG_UT_BOOTSTD
U_BOOT_CMD_MKENT(bootstd, CONFIG_SYS_MAXARGS, 1, do_ut_bootstd,
"", ""),
#endif