aboutsummaryrefslogtreecommitdiff
path: root/components/messaging/ffa/libsp/tests.cmake
diff options
context:
space:
mode:
authorImre Kis <imre.kis@arm.com>2021-01-12 22:22:04 +0100
committerGy├Ârgy Szing <gyorgy.szing@arm.com>2021-02-02 10:00:13 +0000
commitf5f4a554d8d5e6917cbd31ad726e13e9ab055449 (patch)
treee8288bfcabb26e5b645a0823e0f545da83162680 /components/messaging/ffa/libsp/tests.cmake
parentb6a63bfe32d7c6fa4b973ba0ae3bd46cc5c23594 (diff)
downloadtrusted-services-f5f4a554d8d5e6917cbd31ad726e13e9ab055449.tar.gz
libsp: Unit testing sp_memory_management.c
Testing the functions of sp_memory_management.c using the mocked FF-A layer and SP RXTX implementation. The static functions of the file are tested by exporting them through c-picker. Signed-off-by: Imre Kis <imre.kis@arm.com> Change-Id: Ie9995c83b7d9ceb98527bac6685e6f9d555471af
Diffstat (limited to 'components/messaging/ffa/libsp/tests.cmake')
-rw-r--r--components/messaging/ffa/libsp/tests.cmake30
1 files changed, 30 insertions, 0 deletions
diff --git a/components/messaging/ffa/libsp/tests.cmake b/components/messaging/ffa/libsp/tests.cmake
index 39adc97..7096916 100644
--- a/components/messaging/ffa/libsp/tests.cmake
+++ b/components/messaging/ffa/libsp/tests.cmake
@@ -96,3 +96,33 @@ unit_test_add_suite(
COMPILE_DEFINITIONS
-DARM64
)
+
+unit_test_add_suite(
+ NAME libsp_sp_memory_management
+ SOURCES
+ ${CMAKE_CURRENT_LIST_DIR}/test/test_sp_memory_management.cpp
+ ${CMAKE_CURRENT_LIST_DIR}/sp_memory_management.c
+ ${CMAKE_CURRENT_LIST_DIR}/ffa_memory_descriptors.c
+ ${CMAKE_CURRENT_LIST_DIR}/test/mock_assert.cpp
+ ${CMAKE_CURRENT_LIST_DIR}/test/mock_ffa_api.cpp
+ ${CMAKE_CURRENT_LIST_DIR}/test/mock_sp_rxtx.cpp
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_LIST_DIR}/include/
+ ${PROJECT_PATH}/components/common/utils/include
+ COMPILE_DEFINITIONS
+ -DARM64
+)
+
+unit_test_add_suite(
+ NAME libsp_sp_memory_management_internals
+ SOURCES
+ ${CMAKE_CURRENT_LIST_DIR}/test/test_sp_memory_management_internals.cpp
+ ${CMAKE_CURRENT_LIST_DIR}/test/sp_memory_management_internals.yml
+ ${CMAKE_CURRENT_LIST_DIR}/ffa_memory_descriptors.c
+ ${CMAKE_CURRENT_LIST_DIR}/test/mock_assert.cpp
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_LIST_DIR}/include/
+ ${PROJECT_PATH}/components/common/utils/include
+ COMPILE_DEFINITIONS
+ -DARM64
+)