Build: Avoid using CMAKE_SOURCE_DIR in tests

The test suites could be built by other projects in addition to
tests_reg, for example, the RPC test framework.

Change-Id: Id2b7864e31545114adf3a2dd40870dcbf44a3b92
Signed-off-by: Kevin Peng <kevin.peng@arm.com>
diff --git a/tests_reg/test/ns_regression/CMakeLists.txt b/tests_reg/test/ns_regression/CMakeLists.txt
index f780357..122db8d 100644
--- a/tests_reg/test/ns_regression/CMakeLists.txt
+++ b/tests_reg/test/ns_regression/CMakeLists.txt
@@ -32,7 +32,7 @@
     )
 
 # Common regression test framework
-add_subdirectory(${CMAKE_SOURCE_DIR}/test/framework ${CMAKE_CURRENT_BINARY_DIR}/framework)
+add_subdirectory(../framework ${CMAKE_CURRENT_BINARY_DIR}/framework)
 
 add_library(tfm_ns_tests INTERFACE)
 add_library(tfm_test_framework_ns INTERFACE)
@@ -65,6 +65,6 @@
         $<$<BOOL:${TFM_FUZZER_TOOL_TESTS}>:TFM_FUZZER_TOOL_TESTS>
 )
 
-add_subdirectory(${CMAKE_SOURCE_DIR}/test/secure_fw/non_secure
+add_subdirectory(../secure_fw/non_secure
                  ${CMAKE_CURRENT_BINARY_DIR}/secure_fw/suites
 )