ctest: Make cmake test pass if it has been run before
We have to check if the directory exists before calling mkdir or the test will fail on every run but the first one. Change-Id: I36f10cfc18b3cb99990dc96190349ee00a0c1c4e Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
This commit is contained in:
parent
64037f18d3
commit
10f9bd82ea
@ -65,7 +65,8 @@ for (MODULE_UNDER_TEST, CMAKE_QT_MODULES_UNDER_TEST) {
|
||||
CMAKE_MODULES_UNDER_TEST = $$join(CMAKE_MODULES_UNDER_TEST, ;)
|
||||
|
||||
check.commands = \
|
||||
$(MKDIR) $$BUILD_DIR && $$QMAKE_CD $$BUILD_DIR && \
|
||||
$$sprintf($$QMAKE_MKDIR_CMD, $$BUILD_DIR) $$escape_expand(\\n\\t) \
|
||||
$$QMAKE_CD $$BUILD_DIR && \
|
||||
cmake $$CMAKE_TEST_LOCATION $$CMAKE_GENERATOR \
|
||||
-DCMAKE_C_COMPILER=$$QMAKE_CC \
|
||||
-DCMAKE_CXX_COMPILER=$$QMAKE_CXX \
|
||||
|
Loading…
Reference in New Issue
Block a user