From a249b4d188e998ec4673b7c2c2d7f2bbf215406b Mon Sep 17 00:00:00 2001 From: Sebastien Barre Date: Tue, 22 Jan 2002 13:30:06 -0500 Subject: Coverage for OUTPUT_REQUIRED_FILES --- Tests/Complex/Executable/CMakeLists.txt | 9 +++++---- Tests/Complex/Executable/complex.cxx | 2 +- Tests/Complex/Executable/required/CMakeLists.txt | 8 ++++++++ Tests/ComplexOneConfig/Executable/CMakeLists.txt | 9 +++++---- Tests/ComplexOneConfig/Executable/complex.cxx | 2 +- Tests/ComplexOneConfig/Executable/required/CMakeLists.txt | 8 ++++++++ Tests/ComplexRelativePaths/Executable/CMakeLists.txt | 9 +++++---- Tests/ComplexRelativePaths/Executable/complex.cxx | 2 +- Tests/ComplexRelativePaths/Executable/required/CMakeLists.txt | 8 ++++++++ 9 files changed, 42 insertions(+), 15 deletions(-) create mode 100644 Tests/Complex/Executable/required/CMakeLists.txt create mode 100644 Tests/ComplexOneConfig/Executable/required/CMakeLists.txt create mode 100644 Tests/ComplexRelativePaths/Executable/required/CMakeLists.txt diff --git a/Tests/Complex/Executable/CMakeLists.txt b/Tests/Complex/Executable/CMakeLists.txt index 438808f..5cf4054 100644 --- a/Tests/Complex/Executable/CMakeLists.txt +++ b/Tests/Complex/Executable/CMakeLists.txt @@ -25,11 +25,12 @@ TARGET_LINK_LIBRARIES(complex # # Output the files required by 'complex' to a file. -# The 'complex' executable will then test if this file exists and remove it. -# The contents of this file is not tested (absolute paths). # -#OUTPUT_REQUIRED_FILES(${Complex_SOURCE_DIR}/Executable/complex.cxx -# ${Complex_BINARY_DIR}/Executable/complex-required.txt) +# This test has been moved to the 'required' subdir so that it +# has no side-effects on the current Makefile (duplicated source file +# due to source list expansion done twice). +# +SUBDIRS(required) # # Extra coverage.Not used. diff --git a/Tests/Complex/Executable/complex.cxx b/Tests/Complex/Executable/complex.cxx index b0b7b6c..9e24c33 100644 --- a/Tests/Complex/Executable/complex.cxx +++ b/Tests/Complex/Executable/complex.cxx @@ -516,7 +516,7 @@ int main() // the file was removed the last time 'complex' was run, and it is // only created during a build. - // TestAndRemoveFile(BINARY_DIR "/Executable/complex-required.txt"); + TestAndRemoveFile(BINARY_DIR "/Executable/required/complex-required.txt"); // ---------------------------------------------------------------------- // Summary diff --git a/Tests/Complex/Executable/required/CMakeLists.txt b/Tests/Complex/Executable/required/CMakeLists.txt new file mode 100644 index 0000000..4739983 --- /dev/null +++ b/Tests/Complex/Executable/required/CMakeLists.txt @@ -0,0 +1,8 @@ +# +# Output the files required by 'complex' to a file. +# The 'complex' executable will then test if this file exists and remove it. +# The contents of this file is not tested (absolute paths). +# +OUTPUT_REQUIRED_FILES( + ${Complex_SOURCE_DIR}/Executable/complex.cxx + ${Complex_BINARY_DIR}/Executable/required/complex-required.txt) diff --git a/Tests/ComplexOneConfig/Executable/CMakeLists.txt b/Tests/ComplexOneConfig/Executable/CMakeLists.txt index 438808f..5cf4054 100644 --- a/Tests/ComplexOneConfig/Executable/CMakeLists.txt +++ b/Tests/ComplexOneConfig/Executable/CMakeLists.txt @@ -25,11 +25,12 @@ TARGET_LINK_LIBRARIES(complex # # Output the files required by 'complex' to a file. -# The 'complex' executable will then test if this file exists and remove it. -# The contents of this file is not tested (absolute paths). # -#OUTPUT_REQUIRED_FILES(${Complex_SOURCE_DIR}/Executable/complex.cxx -# ${Complex_BINARY_DIR}/Executable/complex-required.txt) +# This test has been moved to the 'required' subdir so that it +# has no side-effects on the current Makefile (duplicated source file +# due to source list expansion done twice). +# +SUBDIRS(required) # # Extra coverage.Not used. diff --git a/Tests/ComplexOneConfig/Executable/complex.cxx b/Tests/ComplexOneConfig/Executable/complex.cxx index b0b7b6c..9e24c33 100644 --- a/Tests/ComplexOneConfig/Executable/complex.cxx +++ b/Tests/ComplexOneConfig/Executable/complex.cxx @@ -516,7 +516,7 @@ int main() // the file was removed the last time 'complex' was run, and it is // only created during a build. - // TestAndRemoveFile(BINARY_DIR "/Executable/complex-required.txt"); + TestAndRemoveFile(BINARY_DIR "/Executable/required/complex-required.txt"); // ---------------------------------------------------------------------- // Summary diff --git a/Tests/ComplexOneConfig/Executable/required/CMakeLists.txt b/Tests/ComplexOneConfig/Executable/required/CMakeLists.txt new file mode 100644 index 0000000..4739983 --- /dev/null +++ b/Tests/ComplexOneConfig/Executable/required/CMakeLists.txt @@ -0,0 +1,8 @@ +# +# Output the files required by 'complex' to a file. +# The 'complex' executable will then test if this file exists and remove it. +# The contents of this file is not tested (absolute paths). +# +OUTPUT_REQUIRED_FILES( + ${Complex_SOURCE_DIR}/Executable/complex.cxx + ${Complex_BINARY_DIR}/Executable/required/complex-required.txt) diff --git a/Tests/ComplexRelativePaths/Executable/CMakeLists.txt b/Tests/ComplexRelativePaths/Executable/CMakeLists.txt index 438808f..5cf4054 100644 --- a/Tests/ComplexRelativePaths/Executable/CMakeLists.txt +++ b/Tests/ComplexRelativePaths/Executable/CMakeLists.txt @@ -25,11 +25,12 @@ TARGET_LINK_LIBRARIES(complex # # Output the files required by 'complex' to a file. -# The 'complex' executable will then test if this file exists and remove it. -# The contents of this file is not tested (absolute paths). # -#OUTPUT_REQUIRED_FILES(${Complex_SOURCE_DIR}/Executable/complex.cxx -# ${Complex_BINARY_DIR}/Executable/complex-required.txt) +# This test has been moved to the 'required' subdir so that it +# has no side-effects on the current Makefile (duplicated source file +# due to source list expansion done twice). +# +SUBDIRS(required) # # Extra coverage.Not used. diff --git a/Tests/ComplexRelativePaths/Executable/complex.cxx b/Tests/ComplexRelativePaths/Executable/complex.cxx index b0b7b6c..9e24c33 100644 --- a/Tests/ComplexRelativePaths/Executable/complex.cxx +++ b/Tests/ComplexRelativePaths/Executable/complex.cxx @@ -516,7 +516,7 @@ int main() // the file was removed the last time 'complex' was run, and it is // only created during a build. - // TestAndRemoveFile(BINARY_DIR "/Executable/complex-required.txt"); + TestAndRemoveFile(BINARY_DIR "/Executable/required/complex-required.txt"); // ---------------------------------------------------------------------- // Summary diff --git a/Tests/ComplexRelativePaths/Executable/required/CMakeLists.txt b/Tests/ComplexRelativePaths/Executable/required/CMakeLists.txt new file mode 100644 index 0000000..4739983 --- /dev/null +++ b/Tests/ComplexRelativePaths/Executable/required/CMakeLists.txt @@ -0,0 +1,8 @@ +# +# Output the files required by 'complex' to a file. +# The 'complex' executable will then test if this file exists and remove it. +# The contents of this file is not tested (absolute paths). +# +OUTPUT_REQUIRED_FILES( + ${Complex_SOURCE_DIR}/Executable/complex.cxx + ${Complex_BINARY_DIR}/Executable/required/complex-required.txt) -- cgit v0.12