From c006bcc636c57daabd6f9ca0094708e37b379258 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tor=20Arne=20Vestb=C3=B8?= Date: Mon, 2 Mar 2015 18:14:04 +0100 Subject: [PATCH] Only run tests for the default exclusive builds target MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We now have support for more complex exclusive builds configurations, e.g., on iOS with simulator and device configurations, so we can't hard code the logic for choosing the right exclusive build to test. Change-Id: I358687b297b7bf1eb28eef0ef0aaf44b89860404 Reviewed-by: Tor Arne Vestbø --- mkspecs/features/testcase.prf | 25 +++++++++---------------- 1 file changed, 9 insertions(+), 16 deletions(-) diff --git a/mkspecs/features/testcase.prf b/mkspecs/features/testcase.prf index c77f3b70ab4..a6ef9301280 100644 --- a/mkspecs/features/testcase.prf +++ b/mkspecs/features/testcase.prf @@ -52,25 +52,18 @@ insignificant_test:check.commands = -$${check.commands} QMAKE_EXTRA_TARGETS *= check -!debug_and_release|build_pass { +isEmpty(BUILDS)|build_pass { check.depends = first } else { + # For exclusive builds, only run the test once. check.CONFIG = recursive - # In debug and release mode, only run the test once. - # Run debug if that is the preferred config, release otherwise. - debug_and_release { - check.target = dummy_check - check.recurse_target = check - CONFIG(debug, debug|release) { - real_check.depends = debug-check - real_check.target = check - QMAKE_EXTRA_TARGETS += real_check - } else { - real_check.depends = release-check - real_check.target = check - QMAKE_EXTRA_TARGETS += real_check - } - } + check.target = check_all + check.recurse_target = check + check.commands = + + check_first.depends = $$eval($$first(BUILDS).target)-check + check_first.target = check + QMAKE_EXTRA_TARGETS += check_first } !no_testcase_installs:!contains(INSTALLS, target) {