Skip to content

Commit

Permalink
[CMake] Update tests to use ADD_UNIT_TEST from the cmake module
Browse files Browse the repository at this point in the history
  • Loading branch information
jcarpent committed Aug 27, 2018
1 parent e4e7e98 commit 00fee22
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ INCLUDE(cmake/base.cmake)
INCLUDE(cmake/idl.cmake)
INCLUDE(cmake/python.cmake)
INCLUDE(cmake/boost.cmake)
INCLUDE(cmake/test.cmake)

SET(PROJECT_NAME gepetto-viewer-corba)
SET(PROJECT_DESCRIPTION "Corba server for gepetto-viewer")
Expand Down
5 changes: 2 additions & 3 deletions tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,10 @@ ADD_DEFINITIONS(${QT_DEFINITIONS})

MACRO(ADD_TESTCASE NAME GENERATED)
IF (${GENERATED} STREQUAL TRUE)
ADD_EXECUTABLE(${NAME} ${CMAKE_CURRENT_BINARY_DIR}/${NAME}.cc)
ADD_UNIT_TEST(${NAME} ${CMAKE_CURRENT_BINARY_DIR}/${NAME}.cc)
ELSE()
ADD_EXECUTABLE(${NAME} ${NAME}.cc)
ADD_UNIT_TEST(${NAME} ${NAME}.cc)
ENDIF()
ADD_TEST(${NAME} ${EXECUTABLE_OUTPUT_PATH}/${NAME})

TARGET_LINK_LIBRARIES(${NAME} ${QT_LIBRARIES})
PKG_CONFIG_USE_DEPENDENCY(${NAME} openscenegraph)
Expand Down

0 comments on commit 00fee22

Please sign in to comment.