Tests: Simplify RunCMake test extra argument passing

Allow add_RunCMake_test calls to pass non-optional arguments
immediately.
This commit is contained in:
Brad King 2014-12-15 16:46:05 -05:00
parent da7155f5bc
commit a85ee8b8cf
1 changed files with 2 additions and 2 deletions

View File

@ -9,6 +9,7 @@ macro(add_RunCMake_test test)
-DRunCMake_SOURCE_DIR=${CMAKE_CURRENT_SOURCE_DIR}/${test} -DRunCMake_SOURCE_DIR=${CMAKE_CURRENT_SOURCE_DIR}/${test}
-DRunCMake_BINARY_DIR=${CMAKE_CURRENT_BINARY_DIR}/${test} -DRunCMake_BINARY_DIR=${CMAKE_CURRENT_BINARY_DIR}/${test}
${${test}_ARGS} ${${test}_ARGS}
${ARGN}
-P "${CMAKE_CURRENT_SOURCE_DIR}/${test}/RunCMakeTest.cmake" -P "${CMAKE_CURRENT_SOURCE_DIR}/${test}/RunCMakeTest.cmake"
) )
endmacro() endmacro()
@ -131,8 +132,7 @@ if (QT4_FOUND AND Qt5Core_FOUND AND NOT Qt5Core_VERSION VERSION_LESS 5.1.0)
add_RunCMake_test(IncompatibleQt) add_RunCMake_test(IncompatibleQt)
endif() endif()
if (QT4_FOUND) if (QT4_FOUND)
set(ObsoleteQtMacros_ARGS -DQT_QMAKE_EXECUTABLE:FILEPATH=${QT_QMAKE_EXECUTABLE}) add_RunCMake_test(ObsoleteQtMacros -DQT_QMAKE_EXECUTABLE:FILEPATH=${QT_QMAKE_EXECUTABLE})
add_RunCMake_test(ObsoleteQtMacros)
endif() endif()
find_package(PkgConfig QUIET) find_package(PkgConfig QUIET)