From 1785b0f56111f10eb81df9977f24c73358e1eb9b Mon Sep 17 00:00:00 2001 From: Robert Loehning Date: Fri, 3 Aug 2018 15:48:20 +0200 Subject: [PATCH] Squish: Use TestSections in tst_create_proj_wizard Change-Id: Ib097f629a1815e9f372e4bdf91faa14b3a7b9042 Reviewed-by: Christian Stenger --- .../tst_create_proj_wizard/test.py | 29 ++++++++++--------- 1 file changed, 15 insertions(+), 14 deletions(-) diff --git a/tests/system/suite_general/tst_create_proj_wizard/test.py b/tests/system/suite_general/tst_create_proj_wizard/test.py index 16834d19b83..c27e8722f3b 100644 --- a/tests/system/suite_general/tst_create_proj_wizard/test.py +++ b/tests/system/suite_general/tst_create_proj_wizard/test.py @@ -68,20 +68,21 @@ def main(): for current in availableProjectTypes: category = current.keys()[0] template = current.values()[0] - displayedPlatforms = __createProject__(category, template) - if template.startswith("Qt Quick Application - "): - qtVersionsForQuick = ["5.6", "5.10"] if template == "Qt Quick Application - Empty" else ["5.10"] - for counter, qtVersion in enumerate(qtVersionsForQuick): - def additionalFunc(displayedPlatforms, qtVersion): - requiredQtVersion = __createProjectHandleQtQuickSelection__(qtVersion) - __modifyAvailableTargets__(displayedPlatforms, requiredQtVersion, True) - handleBuildSystemVerifyKits(category, template, kits, displayedPlatforms, - additionalFunc, qtVersion) - # are there more Quick combinations - then recreate this project - if counter < len(qtVersionsForQuick) - 1: - displayedPlatforms = __createProject__(category, template) - continue - handleBuildSystemVerifyKits(category, template, kits, displayedPlatforms) + with TestSection("Testing project template %s -> %s" % (category, template)): + displayedPlatforms = __createProject__(category, template) + if template.startswith("Qt Quick Application - "): + qtVersionsForQuick = ["5.6", "5.10"] if template == "Qt Quick Application - Empty" else ["5.10"] + for counter, qtVersion in enumerate(qtVersionsForQuick): + def additionalFunc(displayedPlatforms, qtVersion): + requiredQtVersion = __createProjectHandleQtQuickSelection__(qtVersion) + __modifyAvailableTargets__(displayedPlatforms, requiredQtVersion, True) + handleBuildSystemVerifyKits(category, template, kits, displayedPlatforms, + additionalFunc, qtVersion) + # are there more Quick combinations - then recreate this project + if counter < len(qtVersionsForQuick) - 1: + displayedPlatforms = __createProject__(category, template) + continue + handleBuildSystemVerifyKits(category, template, kits, displayedPlatforms) invokeMenuItem("File", "Exit")