Commit f0b4c67b authored by Ben Boeckel's avatar Ben Boeckel Committed by Kitware Robot
Browse files

Merge topic 'output-path-cache-entries'

e5eb7ec2 testing: just use the target names for test binaries
7f8f81d4

 cmake: don't set output paths in the cache
Acked-by: Kitware Robot's avatarKitware Robot <kwrobot@kitware.com>
Acked-by: David Thompson's avatarDavid Thompson <david.thompson@kitware.com>
Merge-request: !6
parents b68f8265 e5eb7ec2
......@@ -62,22 +62,11 @@ include(FindHashFunctor)
# Set the directory where the binaries will be stored
set(EXECUTABLE_OUTPUT_PATH
${PROJECT_BINARY_DIR}/bin
CACHE PATH
"Directory where all executable will be stored"
)
${PROJECT_BINARY_DIR}/bin)
# Set the directory where the libraries will be stored
set(LIBRARY_OUTPUT_PATH
${PROJECT_BINARY_DIR}/lib
CACHE PATH
"Directory where all the libraries will be stored"
)
mark_as_advanced(
EXECUTABLE_OUTPUT_PATH
LIBRARY_OUTPUT_PATH
)
${PROJECT_BINARY_DIR}/lib)
include(CMakeDependentOption)
......
......@@ -27,5 +27,5 @@ include_directories(${CMAKE_CURRENT_BINARY_DIR})
# if (SMTK_ENABLE_CGM_SESSION)
# target_link_libraries(add_a_session smtkCGMSession)
# endif (SMTK_ENABLE_CGM_SESSION)
# add_test(tut-add_a_session ${EXECUTABLE_OUTPUT_PATH}/add_a_session)
# add_test(tut-add_a_session add_a_session)
#endif()
......@@ -27,5 +27,5 @@ if (SMTK_ENABLE_TESTING)
if (SMTK_ENABLE_CGM_SESSION)
target_link_libraries(implement_an_operator smtkCGMSession)
endif (SMTK_ENABLE_CGM_SESSION)
add_test(tut-implement_an_operator ${EXECUTABLE_OUTPUT_PATH}/implement_an_operator)
add_test(tut-implement_an_operator implement_an_operator)
endif()
add_executable(list-cgm-engines list-cgm-engines.cxx)
target_link_libraries(list-cgm-engines smtkCGMSession smtkCore)
add_test(list-cgm-engines ${EXECUTABLE_OUTPUT_PATH}/list-cgm-engines -test-set-default)
add_test(list-cgm-engines list-cgm-engines -test-set-default)
add_executable(test-operators test-operators.cxx)
target_link_libraries(test-operators smtkCGMSession smtkCore ${Boost_LIBRARIES})
add_test(test-operators ${EXECUTABLE_OUTPUT_PATH}/test-operators)
add_test(test-operators test-operators)
ADD_EXECUTABLE(CMBSerializationTest CMBSerializationTest.cxx)
TARGET_LINK_LIBRARIES(CMBSerializationTest vtkCmbDiscreteModel)
add_short_test(ModelBuilderSerializationTest ${EXECUTABLE_OUTPUT_PATH}/CMBSerializationTest)
add_short_test(ModelBuilderSerializationTest CMBSerializationTest)
ADD_EXECUTABLE(CMB2DModelTopologyTest CMB2DModelTopologyTest.cxx)
TARGET_LINK_LIBRARIES(CMB2DModelTopologyTest vtkCmbDiscreteModel)
add_short_test(ModelBuilder2DModelTopologyTest ${EXECUTABLE_OUTPUT_PATH}/CMB2DModelTopologyTest)
add_short_test(ModelBuilder2DModelTopologyTest CMB2DModelTopologyTest)
ADD_EXECUTABLE(CMBParserV4Test CMBParserV4Test.cxx)
TARGET_LINK_LIBRARIES(CMBParserV4Test vtkCmbDiscreteModel)
add_short_test(ModelBuilderParserV4Test
${EXECUTABLE_OUTPUT_PATH}/CMBParserV4Test
CMBParserV4Test
${CMB_TEST_DATA_ROOT}/CMBParserV4Test.cmb )
ADD_EXECUTABLE(CMBModelEventsTest CMBModelEventsTest.cxx)
TARGET_LINK_LIBRARIES(CMBModelEventsTest vtkCmbDiscreteModel)
add_short_test(ModelBuilderModelEventsTest
${EXECUTABLE_OUTPUT_PATH}/CMBModelEventsTest
CMBModelEventsTest
${CMB_TEST_DATA_ROOT}/test2D.cmb ${CMB_TEST_DATA_ROOT}/smooth_surface.cmb)
ADD_EXECUTABLE(BridgeTest BridgeTest.cxx)
TARGET_LINK_LIBRARIES(BridgeTest vtkCmbDiscreteModel smtkCore)
ADD_TEST(BridgeTest
${EXECUTABLE_OUTPUT_PATH}/BridgeTest
BridgeTest
${CMB_TEST_DATA_ROOT}/test2D.cmb ${CMB_TEST_DATA_ROOT}/smooth_surface.cmb)
......@@ -4,15 +4,15 @@ include_directories(${SimBuilderMesh_SOURCE_DIR})
add_executable(SimBuilderMeshEventsTest SimBuilderMeshEventsTest.cxx)
target_link_libraries(SimBuilderMeshEventsTest SimBuilderMeshPlugin)
add_short_test(SimBuilderMeshEventsTest ${EXECUTABLE_OUTPUT_PATH}/SimBuilderMeshEventsTest
add_short_test(SimBuilderMeshEventsTest SimBuilderMeshEventsTest
${CMB_TEST_DATA_ROOT}/test2D.cmb)
add_executable(SimBuilderMeshEventsTest2 SimBuilderMeshEventsTest2.cxx)
target_link_libraries(SimBuilderMeshEventsTest2 SimBuilderMeshPlugin)
add_short_test(SimBuilderMeshEventsTest2 ${EXECUTABLE_OUTPUT_PATH}/SimBuilderMeshEventsTest2
add_short_test(SimBuilderMeshEventsTest2 SimBuilderMeshEventsTest2
${CMB_TEST_DATA_ROOT}/bay.cmb)
add_executable(SimBuilderMeshRelationTest SimBuilderMeshRelationTest.cxx)
target_link_libraries(SimBuilderMeshRelationTest SimBuilderMeshPlugin)
add_short_test(SimBuilderMeshRelationTest ${EXECUTABLE_OUTPUT_PATH}/SimBuilderMeshRelationTest
add_short_test(SimBuilderMeshRelationTest SimBuilderMeshRelationTest
${CMB_TEST_DATA_ROOT}/test2D.cmb)
ADD_EXECUTABLE(DiscreteSerializationTest DiscreteSerializationTest.cxx)
TARGET_LINK_LIBRARIES(DiscreteSerializationTest smtkDiscreteSession vtkSMTKDiscreteModel)
add_test(discreteModelSerializationTest ${EXECUTABLE_OUTPUT_PATH}/DiscreteSerializationTest)
add_test(discreteModelSerializationTest DiscreteSerializationTest)
ADD_EXECUTABLE(Discrete2DModelTopologyTest Discrete2DModelTopologyTest.cxx)
TARGET_LINK_LIBRARIES(Discrete2DModelTopologyTest smtkDiscreteSession vtkSMTKDiscreteModel)
add_test(discreteModel2DModelTopologyTest ${EXECUTABLE_OUTPUT_PATH}/Discrete2DModelTopologyTest)
add_test(discreteModel2DModelTopologyTest Discrete2DModelTopologyTest)
# ADD_EXECUTABLE(DiscreteParserV4Test DiscreteParserV4Test.cxx)
# TARGET_LINK_LIBRARIES(DiscreteParserV4Test smtkDiscreteSession vtkSMTKDiscreteModel)
# add_test(discreteModelParserV4Test
# ${EXECUTABLE_OUTPUT_PATH}/DiscreteParserV4Test
# DiscreteParserV4Test
# ${SMTK_DATA_DIR}/cmb/CMBParserV4Test.cmb )
# ADD_EXECUTABLE(DiscreteModelEventsTest DiscreteModelEventsTest.cxx)
# TARGET_LINK_LIBRARIES(DiscreteModelEventsTest smtkDiscreteSession)
# add_test(ModelBuilderModelEventsTest
# ${EXECUTABLE_OUTPUT_PATH}/DiscreteModelEventsTest
# DiscreteModelEventsTest
# ${SMTK_DATA_DIR}/test2D.cmb ${SMTK_DATA_DIR}/smooth_surface.cmb)
......@@ -2,6 +2,6 @@ if(SMTK_DATA_DIR)
ADD_EXECUTABLE(SessionTest SessionTest.cxx)
TARGET_LINK_LIBRARIES(SessionTest smtkCore smtkDiscreteSession)
ADD_TEST(discreteSessionTest
${EXECUTABLE_OUTPUT_PATH}/SessionTest
SessionTest
${SMTK_DATA_DIR}/cmb/test2D.cmb ${SMTK_DATA_DIR}/cmb/smooth_surface.cmb)
endif()
......@@ -7,7 +7,7 @@ set(ioTests
foreach (test ${ioTests})
add_executable(${test} ${test}.cxx)
target_link_libraries(${test} smtkCore smtkCoreModelTesting)
add_test(${test} ${EXECUTABLE_OUTPUT_PATH}/${test})
add_test(${test} ${test})
endforeach()
......@@ -17,7 +17,7 @@ if (SMTK_DATA_DIR)
add_executable(${writer_test} ${writer_test}.cxx)
target_link_libraries(${writer_test} smtkCore ${Boost_LIBRARIES})
add_test(${writer_test}
${EXECUTABLE_OUTPUT_PATH}/${writer_test}
${writer_test}
${SMTK_DATA_DIR}/smtk/attribute/Basic2DFluid.sbt
${SMTK_DATA_DIR}/smtk/attribute/copyAttributeTest.sbi
writer_output.crf
......@@ -27,7 +27,7 @@ if (SMTK_DATA_DIR)
add_executable(${reader_test} ${reader_test}.cxx)
target_link_libraries(${reader_test} smtkCore ${Boost_LIBRARIES})
add_test(${reader_test}
${EXECUTABLE_OUTPUT_PATH}/${reader_test}
${reader_test}
${SMTK_DATA_DIR}/smtk/attribute/resourceTest/resources.xml
2
)
......
......@@ -18,15 +18,15 @@ target_link_libraries(demoReportArrangements smtkCore smtkCoreModelTesting)
################################################################################
add_executable(unitManager unitManager.cxx)
target_link_libraries(unitManager smtkCore smtkCoreModelTesting)
add_test(unitManager ${EXECUTABLE_OUTPUT_PATH}/unitManager)
add_test(unitManager unitManager)
add_executable(unitIterators unitIterators.cxx)
target_link_libraries(unitIterators smtkCore smtkCoreModelTesting)
add_test(unitIterators ${EXECUTABLE_OUTPUT_PATH}/unitIterators)
add_test(unitIterators unitIterators)
add_executable(unitTessellation unitTessellation.cxx)
target_link_libraries(unitTessellation smtkCore smtkCoreModelTesting)
add_test(unitTessellation ${EXECUTABLE_OUTPUT_PATH}/unitTessellation)
add_test(unitTessellation unitTessellation)
add_executable(unitOperator unitOperator.cxx)
smtk_operator_xml( "${CMAKE_CURRENT_SOURCE_DIR}/unitOutcomeOperator.sbt" unitOperatorXML)
......@@ -35,37 +35,37 @@ target_link_libraries(unitOperator smtkCore smtkCoreModelTesting)
if (SMTK_ENABLE_CGM_SESSION)
target_link_libraries(unitOperator smtkCGMSession)
endif (SMTK_ENABLE_CGM_SESSION)
add_test(unitOperator ${EXECUTABLE_OUTPUT_PATH}/unitOperator)
add_test(unitOperator unitOperator)
add_executable(unitEntityRef unitEntityRef.cxx)
target_link_libraries(unitEntityRef smtkCore smtkCoreModelTesting)
add_test(unitEntityRef ${EXECUTABLE_OUTPUT_PATH}/unitEntityRef)
add_test(unitEntityRef unitEntityRef)
add_executable(unitDefaultSession unitDefaultSession.cxx)
smtk_operator_xml( "${CMAKE_CURRENT_SOURCE_DIR}/unitForwardingOperator.sbt" unitOperatorXML)
target_include_directories(unitDefaultSession PRIVATE "${CMAKE_CURRENT_BINARY_DIR}")
target_link_libraries(unitDefaultSession smtkCore smtkCoreModelTesting)
add_test(unitDefaultSession ${EXECUTABLE_OUTPUT_PATH}/unitDefaultSession)
add_test(unitDefaultSession unitDefaultSession)
add_executable(unitDescriptivePhrase unitDescriptivePhrase.cxx)
target_link_libraries(unitDescriptivePhrase smtkCore smtkCoreModelTesting)
add_executable(unitArrangement unitArrangement.cxx)
target_link_libraries(unitArrangement smtkCore)
add_test(unitArrangement ${EXECUTABLE_OUTPUT_PATH}/unitArrangement)
add_test(unitArrangement unitArrangement)
add_executable(unitEntity unitEntity.cxx)
target_link_libraries(unitEntity smtkCore smtkCoreModelTesting)
add_test(unitEntity ${EXECUTABLE_OUTPUT_PATH}/unitEntity)
add_test(unitEntity unitEntity)
add_executable(benchmarkModel benchmarkModel.cxx)
target_link_libraries(benchmarkModel smtkCore smtkCoreModelTesting)
#add_test(benchmarkModel ${EXECUTABLE_OUTPUT_PATH}/benchmarkModel)
#add_test(benchmarkModel benchmarkModel)
################################################################################
# Tests that require SMTK_DATA_DIR
################################################################################
if (SMTK_DATA_DIR AND EXISTS ${SMTK_DATA_DIR}/ReadMe.mkd)
add_test(unitDescriptivePhrase ${EXECUTABLE_OUTPUT_PATH}/unitDescriptivePhrase
add_test(unitDescriptivePhrase unitDescriptivePhrase
"${SMTK_DATA_DIR}/smtk/simple.json")
endif()
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment