ENABLE_TESTING()
INCLUDE( CTest )

MACRO( OPENSYNC_ADD_TEST _testName _testSource _targetLibraries ) 

  ADD_EXECUTABLE( ${_testName} ${_testSource} )
  TARGET_LINK_LIBRARIES( ${_testName} ${_targetLibraries} )
  ADD_TEST( ${_testName} ${CMAKE_CURRENT_BINARY_DIR}/${_testName} )

ENDMACRO( OPENSYNC_ADD_TEST )

ENABLE_TESTING()
INCLUDE( CTest )

MACRO( OPENSYNC_ADD_TEST _testName _testSource ) 

  ADD_EXECUTABLE( ${_testName} ${_testSource} )
  TARGET_LINK_LIBRARIES( ${_testName} ${ARGN} )
  ADD_TEST( ${_testName} ${CMAKE_CURRENT_BINARY_DIR}/${_testName} )

ENDMACRO( OPENSYNC_ADD_TEST )

Allow serveral target libraries as last argument. Unfortunately only one testcase sources file is allowed for now...
Allow serveral target libraries as last argument.
Unfortunately only one testcase sources file is allowed for now...


git-svn-id: e31799a7ad59d6ea355ca047c69e0aee8a59fcd3@2714 53f5c7ee-bee3-0310-bbc5-ea0e15fffd5e
