summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile20
1 files changed, 15 insertions, 5 deletions
diff --git a/Makefile b/Makefile
index 981bd3ab..282ee932 100644
--- a/Makefile
+++ b/Makefile
@@ -183,6 +183,11 @@ ifneq (${TPM2_MODE},)
CFLAGS += -DTPM2_MODE
endif
+# Some tests need to be disabled when using mocked_secdata_tpm.
+ifneq (${MOCK_TPM},)
+CFLAGS += -DMOCK_TPM
+endif
+
# enable all features during local compile (permits testing)
ifeq (${FIRMWARE_ARCH},)
DIAGNOSTIC_UI := 1
@@ -693,13 +698,16 @@ TEST_NAMES = \
tests/vboot_kernel_tests \
tests/verify_kernel
-ifeq (${TPM2_MODE}${MOCK_TPM},)
-# TODO(apronin): tests for TPM2 case?
+ifeq (${MOCK_TPM},)
# secdata_tpm_tests and tlcl_tests only work when MOCK_TPM is disabled
TEST_NAMES += \
- tests/secdata_tpm_tests \
+ tests/secdata_tpm_tests
+ifeq (${TPM2_MODE},)
+# TODO(apronin): tests for TPM2 case?
+TEST_NAMES += \
tests/tlcl_tests
endif
+endif
TEST_FUTIL_NAMES = \
tests/futility/binary_editor \
@@ -1259,12 +1267,14 @@ runtestscripts: test_setup genfuzztestcases
.PHONY: runmisctests
runmisctests: test_setup
-ifeq (${TPM2_MODE}${MOCK_TPM},)
-# TODO(apronin): tests for TPM2 case?
+ifeq (${MOCK_TPM},)
# secdata_tpm_tests and tlcl_tests only work when MOCK_TPM is disabled
${RUNTEST} ${BUILD_RUN}/tests/secdata_tpm_tests
+ifeq (${TPM2_MODE},)
+# TODO(apronin): tests for TPM2 case?
${RUNTEST} ${BUILD_RUN}/tests/tlcl_tests
endif
+endif
${RUNTEST} ${BUILD_RUN}/tests/utility_string_tests
${RUNTEST} ${BUILD_RUN}/tests/vboot_api_devmode_tests
${RUNTEST} ${BUILD_RUN}/tests/vboot_api_kernel2_tests