aboutsummaryrefslogtreecommitdiff
path: root/tests/lib/Makefile.inc
diff options
context:
space:
mode:
authorJakub Czapiga <jacz@semihalf.com>2021-07-27 17:04:11 +0200
committerJulius Werner <jwerner@chromium.org>2021-09-14 23:35:38 +0000
commitb20aa094cc3e83abd106c5e7ef93ed6cde3e7cd7 (patch)
tree5a80e3b33a5f3ff4763a9d93b07862b3b912e513 /tests/lib/Makefile.inc
parent4095291808b04544346432ca675e6fbfbb7ed11c (diff)
tests: Add lib/cbfs-lookup-test test case
Signed-off-by: Jakub Czapiga <jacz@semihalf.com> Change-Id: I2ebebba1468c19661741de8a8456605b1c5f56b6 Reviewed-on: https://review.coreboot.org/c/coreboot/+/56813 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Julius Werner <jwerner@chromium.org>
Diffstat (limited to 'tests/lib/Makefile.inc')
-rw-r--r--tests/lib/Makefile.inc23
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/lib/Makefile.inc b/tests/lib/Makefile.inc
index 44679eb08a..f28cd52fa0 100644
--- a/tests/lib/Makefile.inc
+++ b/tests/lib/Makefile.inc
@@ -36,6 +36,8 @@ tests-y += cbfs-verification-no-sha512-test
tests-y += cbfs-verification-has-sha512-test
tests-y += cbfs-no-verification-no-sha512-test
tests-y += cbfs-no-verification-has-sha512-test
+tests-y += cbfs-lookup-no-mcache-test
+tests-y += cbfs-lookup-has-mcache-test
string-test-srcs += tests/lib/string-test.c
string-test-srcs += src/lib/string.c
@@ -208,3 +210,24 @@ cbfs-no-verification-no-sha512-test-config += CONFIG_CBFS_VERIFICATION=0
$(call copy-test,cbfs-verification-no-sha512-test,cbfs-no-verification-has-sha512-test)
cbfs-no-verification-has-sha512-test-config += CONFIG_CBFS_VERIFICATION=0 \
VB2_SUPPORT_SHA512=1
+
+cbfs-lookup-no-mcache-test-srcs = tests/lib/cbfs-lookup-test.c \
+ tests/stubs/console.c \
+ tests/stubs/die.c \
+ tests/mock/cbfs_file_mock.c \
+ src/lib/cbfs.c \
+ src/commonlib/bsd/cbfs_private.c \
+ src/commonlib/bsd/cbfs_mcache.c \
+ src/commonlib/mem_pool.c \
+ src/commonlib/region.c
+cbfs-lookup-no-mcache-test-mocks += cbfs_get_boot_device \
+ cbfs_lookup \
+ cbfs_mcache_lookup \
+ mem_pool_alloc \
+ mem_pool_free
+cbfs-lookup-no-mcache-test-config += CONFIG_ARCH_X86=0 \
+ CONFIG_COLLECT_TIMESTAMPS=0 \
+ CONFIG_NO_CBFS_MCACHE=1
+
+$(call copy-test,cbfs-lookup-no-mcache-test,cbfs-lookup-has-mcache-test)
+cbfs-lookup-has-mcache-test-config += CONFIG_NO_CBFS_MCACHE=0