diff options
author | Ben Boeckel <ben.boeckel@kitware.com> | 2010-12-17 16:06:59 (GMT) |
---|---|---|
committer | Ben Boeckel <ben.boeckel@kitware.com> | 2010-12-17 16:06:59 (GMT) |
commit | 017d4e9d2ce1544aab44f87204b5195e0c062812 (patch) | |
tree | 75ba8c4eab090995dcf286099caf022f5cf362b6 /Tests/TestsWorkingDirectory | |
parent | 561cc3359cca42749f797dd5ea908531740a873d (diff) | |
download | CMake-017d4e9d2ce1544aab44f87204b5195e0c062812.zip CMake-017d4e9d2ce1544aab44f87204b5195e0c062812.tar.gz CMake-017d4e9d2ce1544aab44f87204b5195e0c062812.tar.bz2 |
Group adding tests with its properties
Diffstat (limited to 'Tests/TestsWorkingDirectory')
-rw-r--r-- | Tests/TestsWorkingDirectory/CMakeLists.txt | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/Tests/TestsWorkingDirectory/CMakeLists.txt b/Tests/TestsWorkingDirectory/CMakeLists.txt index bd52cd6..1bc0705 100644 --- a/Tests/TestsWorkingDirectory/CMakeLists.txt +++ b/Tests/TestsWorkingDirectory/CMakeLists.txt @@ -8,9 +8,6 @@ enable_testing() set(EXECUTABLE_OUTPUT_PATH "${CMAKE_BINARY_DIR}/bin") add_test(NAME WorkingDirectory1 COMMAND WorkingDirectory) -add_test(NAME WorkingDirectory2 COMMAND WorkingDirectory) -add_test(WorkingDirectory3 WorkingDirectory) - set_tests_properties(WorkingDirectory1 PROPERTIES WORKING_DIRECTORY "${CMAKE_BINARY_DIR}" PASS_REGULAR_EXPRESSION "Working directory: -->${CMAKE_BINARY_DIR}<--" @@ -18,6 +15,7 @@ set_tests_properties(WorkingDirectory1 PROPERTIES string(REGEX REPLACE "/[^/]*$" "" _parent_dir "${CMAKE_BINARY_DIR}") +add_test(NAME WorkingDirectory2 COMMAND WorkingDirectory) set_tests_properties(WorkingDirectory2 PROPERTIES WORKING_DIRECTORY "${CMAKE_BINARY_DIR}/.." PASS_REGULAR_EXPRESSION "Working directory: -->${_parent_dir}<--" @@ -27,27 +25,27 @@ get_filename_component(_default_cwd "${EXECUTABLE_OUTPUT_PATH}" PATH) # FIXME: How to deal with /debug, /release, etc. with VS or XCode? if(${CMAKE_GENERATOR} MATCHES "Makefiles") +add_test(WorkingDirectory3 WorkingDirectory) set_tests_properties(WorkingDirectory3 PROPERTIES PASS_REGULAR_EXPRESSION "Working directory: -->${_default_cwd}<--" ) endif() add_test(NAME WorkingDirectory4 WORKING_DIRECTORY ${CMAKE_BINARY_DIR} COMMAND WorkingDirectory) -add_test(NAME WorkingDirectory5 WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/.. COMMAND WorkingDirectory) -add_test(WorkingDirectory6 WorkingDirectory WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/..) - set_tests_properties(WorkingDirectory4 PROPERTIES PASS_REGULAR_EXPRESSION "Working directory: -->${CMAKE_BINARY_DIR}<--" ) string(REGEX REPLACE "/[^/]*$" "" _parent_dir "${CMAKE_BINARY_DIR}") +add_test(NAME WorkingDirectory5 WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/.. COMMAND WorkingDirectory) set_tests_properties(WorkingDirectory5 PROPERTIES PASS_REGULAR_EXPRESSION "Working directory: -->${_parent_dir}<--" ) # FIXME: How to deal with /debug, /release, etc. with VS or XCode? if(${CMAKE_GENERATOR} MATCHES "Makefiles") +add_test(WorkingDirectory6 WorkingDirectory WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/..) set_tests_properties(WorkingDirectory6 PROPERTIES PASS_REGULAR_EXPRESSION "Working directory: -->${_default_cwd}<--" ) |