forked from qt-creator/qt-creator
SquishTests: Update tst_create_proj_wizard
Change-Id: Id17f5d1a68da7fe7c9f45dc5b62ab3fe1039f753 Reviewed-by: Christian Stenger <christian.stenger@qt.io> Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
This commit is contained in:
@@ -125,8 +125,8 @@ def __handleBuildSystem__(buildSystem):
|
|||||||
return buildSystem
|
return buildSystem
|
||||||
|
|
||||||
def __createProjectHandleQtQuickSelection__(minimumQtVersion):
|
def __createProjectHandleQtQuickSelection__(minimumQtVersion):
|
||||||
comboBox = waitForObject("{name='MinimumSupportedQtVersion' type='QComboBox' "
|
comboBox = waitForObject("{name?='*QtVersion' type='QComboBox' visible='1'"
|
||||||
"visible='1' window=':New_ProjectExplorer::JsonWizard'}")
|
" window=':New_ProjectExplorer::JsonWizard'}")
|
||||||
try:
|
try:
|
||||||
selectFromCombo(comboBox, minimumQtVersion)
|
selectFromCombo(comboBox, minimumQtVersion)
|
||||||
except:
|
except:
|
||||||
@@ -505,7 +505,7 @@ def __getSupportedPlatforms__(text, templateName, getAsStrings=False, ignoreVali
|
|||||||
version = res.group("version")
|
version = res.group("version")
|
||||||
else:
|
else:
|
||||||
version = None
|
version = None
|
||||||
if "Qt Quick" in templateName:
|
if templateName == "Qt Quick Application":
|
||||||
result = set([Targets.DESKTOP_6_2_4])
|
result = set([Targets.DESKTOP_6_2_4])
|
||||||
elif 'Supported Platforms' in text:
|
elif 'Supported Platforms' in text:
|
||||||
supports = text[text.find('Supported Platforms'):].split(":")[1].strip().split("\n")
|
supports = text[text.find('Supported Platforms'):].split(":")[1].strip().split("\n")
|
||||||
|
@@ -53,11 +53,18 @@ def main():
|
|||||||
template = list(current.values())[0]
|
template = list(current.values())[0]
|
||||||
with TestSection("Testing project template %s -> %s" % (category, template)):
|
with TestSection("Testing project template %s -> %s" % (category, template)):
|
||||||
displayedPlatforms = __createProject__(category, template)
|
displayedPlatforms = __createProject__(category, template)
|
||||||
if template == "Qt Quick Application":
|
if template.startswith("Qt Quick Application"):
|
||||||
qtVersionsForQuick = ["6.2"]
|
if "(compat)" in template: # QTCREATORBUG-29126
|
||||||
|
qtVersionsForQuick = ["Qt 5.14", "Qt 6.2"]
|
||||||
|
else:
|
||||||
|
qtVersionsForQuick = ["6.2"]
|
||||||
for counter, qtVersion in enumerate(qtVersionsForQuick):
|
for counter, qtVersion in enumerate(qtVersionsForQuick):
|
||||||
def additionalFunc(displayedPlatforms, qtVersion):
|
def additionalFunc(displayedPlatforms, qtVersion):
|
||||||
requiredQtVersion = __createProjectHandleQtQuickSelection__(qtVersion)
|
requiredQtVersion = __createProjectHandleQtQuickSelection__(qtVersion)
|
||||||
|
if sys.version_info.major > 2:
|
||||||
|
requiredQtVersion = requiredQtVersion.removeprefix("Qt ")
|
||||||
|
else:
|
||||||
|
requiredQtVersion = requiredQtVersion.lstrip("Qt ")
|
||||||
__modifyAvailableTargets__(displayedPlatforms, requiredQtVersion, True)
|
__modifyAvailableTargets__(displayedPlatforms, requiredQtVersion, True)
|
||||||
handleBuildSystemVerifyKits(category, template, kits, displayedPlatforms,
|
handleBuildSystemVerifyKits(category, template, kits, displayedPlatforms,
|
||||||
additionalFunc, qtVersion)
|
additionalFunc, qtVersion)
|
||||||
@@ -120,7 +127,7 @@ def handleBuildSystemVerifyKits(category, template, kits, displayedPlatforms,
|
|||||||
clickButton(waitForObject(":Next_QPushButton"))
|
clickButton(waitForObject(":Next_QPushButton"))
|
||||||
if specialHandlingFunc:
|
if specialHandlingFunc:
|
||||||
specialHandlingFunc(displayedPlatforms, *args)
|
specialHandlingFunc(displayedPlatforms, *args)
|
||||||
if not ('Plain C' in template or 'Qt Quick' in template):
|
if not ('Plain C' in template or template == 'Qt Quick Application'):
|
||||||
__createProjectHandleTranslationSelection__()
|
__createProjectHandleTranslationSelection__()
|
||||||
verifyKitCheckboxes(kits, displayedPlatforms)
|
verifyKitCheckboxes(kits, displayedPlatforms)
|
||||||
safeClickButton("Cancel")
|
safeClickButton("Cancel")
|
||||||
|
Reference in New Issue
Block a user