forked from qt-creator/qt-creator
Squish: Update suite_SCOM
Change-Id: I341efe4dc6440f8d8773a27a3dcc754c1151241c Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
This commit is contained in:
committed by
Christian Stenger
parent
fe34bf5c1c
commit
96f03dc09d
@@ -107,6 +107,7 @@
|
||||
:JavaScript.QmlProfilerEventsTable_QmlProfiler::Internal::QV8ProfilerEventsMainView {container=':*Qt Creator.JavaScript_QDockWidget' name='QmlProfilerEventsTable' type='QmlProfiler::Internal::QV8ProfilerEventsMainView' visible='1'}
|
||||
:Kits_QtVersion_QComboBox {container=':qt_tabwidget_stackedwidget_QWidget' occurrence='5' type='QComboBox' unnamed='1' visible='1'}
|
||||
:Locals and Expressions_Debugger::Internal::WatchTreeView {container=':DebugModeWidget.Locals and Expressions_QDockWidget' name='WatchWindow' type='Debugger::Internal::WatchTreeView' visible='1' windowTitle='Locals and Expressions'}
|
||||
:Minimal required Qt version:_QLabel {text='Minimal required Qt version:' type='QLabel' unnamed='1' visible='1' window=':New Text File_ProjectExplorer::JsonWizard'}
|
||||
:New Text File.Add to project:_QLabel {name='projectLabel' text='Add to project:' type='QLabel' visible='1' window=':New Text File_ProjectExplorer::JsonWizard'}
|
||||
:New Text File.nameLineEdit_Utils::FileNameValidatingLineEdit {name='nameLineEdit' type='Utils::FileNameValidatingLineEdit' visible='1' window=':New Text File_ProjectExplorer::JsonWizard'}
|
||||
:New Text File_ProjectExplorer::JsonWizard {type='ProjectExplorer::JsonWizard' unnamed='1' visible='1'}
|
||||
|
@@ -131,21 +131,16 @@ def __createProjectSetNameAndPath__(path, projectName = None, checks = True, lib
|
||||
clickButton(waitForObject(":Next_QPushButton"))
|
||||
return str(projectName)
|
||||
|
||||
def __createProjectHandleQtQuickSelection__(qtQuickOrControlsVersion):
|
||||
comboBox = waitForObject("{type='QComboBox' unnamed='1' visible='1' "
|
||||
"leftWidget={text='Qt Quick component set:' type='QLabel' unnamed='1' "
|
||||
"visible='1'}}")
|
||||
def __createProjectHandleQtQuickSelection__(minimumQtVersion):
|
||||
comboBox = waitForObject("{buddy=':Minimal required Qt version:_QLabel' name='QtVersion' "
|
||||
"type='Utils::TextFieldComboBox' visible='1'}")
|
||||
try:
|
||||
selectFromCombo(comboBox, "Qt Quick %s" % qtQuickOrControlsVersion)
|
||||
selectFromCombo(comboBox, "Qt %s" % minimumQtVersion)
|
||||
except:
|
||||
t,v = sys.exc_info()[:2]
|
||||
test.fatal("Exception while trying to select Qt Quick version", "%s (%s)" % (str(t), str(v)))
|
||||
label = waitForObject("{type='QLabel' unnamed='1' visible='1' text?='Creates a *' }")
|
||||
requires = re.match(".*Requires Qt (\d\.\d).*", str(label.text))
|
||||
if requires:
|
||||
requires = requires.group(1)
|
||||
test.fatal("Exception while trying to select Qt version", "%s (%s)" % (str(t), str(v)))
|
||||
clickButton(waitForObject(":Next_QPushButton"))
|
||||
return requires
|
||||
return minimumQtVersion
|
||||
|
||||
# Selects the Qt versions for a project
|
||||
# param checks turns tests in the function on if set to True
|
||||
@@ -274,11 +269,11 @@ def createProject_Qt_Console(path, projectName, checks = True):
|
||||
return checkedTargets
|
||||
|
||||
def createNewQtQuickApplication(workingDir, projectName = None,
|
||||
targets=Targets.desktopTargetClasses(), qtQuickVersion="1.1",
|
||||
targets=Targets.desktopTargetClasses(), minimumQtVersion="5.3",
|
||||
fromWelcome=False):
|
||||
available = __createProjectOrFileSelectType__(" Application", "Qt Quick Application", fromWelcome)
|
||||
projectName = __createProjectSetNameAndPath__(workingDir, projectName)
|
||||
requiredQt = __createProjectHandleQtQuickSelection__(qtQuickVersion)
|
||||
requiredQt = __createProjectHandleQtQuickSelection__(minimumQtVersion)
|
||||
__modifyAvailableTargets__(available, requiredQt)
|
||||
checkedTargets = __chooseTargets__(targets, available)
|
||||
snooze(1)
|
||||
|
@@ -44,7 +44,7 @@ def main():
|
||||
checkedTargets, projectName = createNewQtQuickApplication(tempDir(), "SampleApp")
|
||||
# create syntax error in cpp file
|
||||
openDocument("SampleApp.Sources.main\\.cpp")
|
||||
if not appendToLine(waitForObject(":Qt Creator_CppEditor::Internal::CPPEditorWidget"), "viewer.showExpanded();", "SyntaxError"):
|
||||
if not appendToLine(waitForObject(":Qt Creator_CppEditor::Internal::CPPEditorWidget"), "QQmlApplicationEngine engine;", "SyntaxError"):
|
||||
invokeMenuItem("File", "Exit")
|
||||
return
|
||||
# save all
|
||||
|
Reference in New Issue
Block a user