Testing object_pool

Add unit tests for object_pool functions. It need a C wrapper because
the macros for creating pool do not work when compiling in C++. The
declaration and initialization order of structure members must be the
same in C++ while this is not a requirement in C.

Change-Id: Id06bcd39cabfcbb57584c8ef7f8a118e3226c3c2
Signed-off-by: Imre Kis <imre.kis@arm.com>
diff --git a/tests/lib/object_pool/test_object_pool.cmake b/tests/lib/object_pool/test_object_pool.cmake
new file mode 100644
index 0000000..d3ef9a5
--- /dev/null
+++ b/tests/lib/object_pool/test_object_pool.cmake
@@ -0,0 +1,21 @@
+#
+# Copyright (c) 2019-2020, Arm Limited. All rights reserved.
+#
+# SPDX-License-Identifier: BSD-3-Clause
+#
+
+include(UnitTest)
+
+unit_test_add_suite(
+	NAME object_pool
+	SOURCES
+		${CMAKE_CURRENT_LIST_DIR}/test_object_pool.cpp
+		${CMAKE_CURRENT_LIST_DIR}/object_pool_allocator_wrapper.c
+		${TF_A_UNIT_TESTS_PATH}/mocks/common/debug.cpp
+	INCLUDE_DIRECTORIES
+		${TF_A_UNIT_TESTS_PATH}/mocks/include/
+		${TF_A_UNIT_TESTS_PATH}/mocks/include/lib/libc/
+		${TF_A_PATH}/include
+	COMPILE_DEFINITIONS
+		LOG_LEVEL=50
+)