diff options
Diffstat (limited to 'src/components/rpc_base/test/CMakeLists.txt')
-rw-r--r-- | src/components/rpc_base/test/CMakeLists.txt | 31 |
1 files changed, 17 insertions, 14 deletions
diff --git a/src/components/rpc_base/test/CMakeLists.txt b/src/components/rpc_base/test/CMakeLists.txt index 566f0ddcde..76cf738f46 100644 --- a/src/components/rpc_base/test/CMakeLists.txt +++ b/src/components/rpc_base/test/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (c) 2016, Ford Motor Company +# Copyright (c) 2015, Ford Motor Company # All rights reserved. # # Redistribution and use in source and binary forms, with or without @@ -28,9 +28,8 @@ # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. -include(${CMAKE_SOURCE_DIR}/tools/cmake/helpers/sources.cmake) - -include_directories( +if (BUILD_TESTS) + include_directories ( ${COMPONENTS_DIR}/dbus/include ${COMPONENTS_DIR}/dbus/src ${COMPONENTS_DIR}/rpc_base/include @@ -44,16 +43,20 @@ set(LIBRARIES jsoncpp ) -if(${HMI_DBUS_API}) +set(SOURCES + rpc_base_json_test.cc + rpc_base_test.cc + validation_report_test.cc +) + +if (${HMI_DBUS_API}) + # Build dbus tests include_directories(${DBUS_INCLUDE_DIRS}) - list(APPEND LIBRARIES - DBus - ) -else() - set(EXCLUDE_PATHS - rpc_base_dbus_test.cc - ) + set (LIBRARIES ${LIBRARIES} DBus) + set (SOURCES ${SOURCES} rpc_base_dbus_test.cc) +endif () + +create_test("rpc_base_test" "${SOURCES}" "${LIBRARIES}") + endif() -collect_sources(SOURCES "${CMAKE_CURRENT_SOURCE_DIR}" "${EXCLUDE_PATHS}") -create_test(rpc_base_test "${SOURCES}" "${LIBRARIES}") |