diff options
author | Eike Ziller <eike.ziller@digia.com> | 2014-01-08 11:01:06 +0100 |
---|---|---|
committer | Eike Ziller <eike.ziller@digia.com> | 2014-01-08 11:01:06 +0100 |
commit | 236ea9efb912c90cf3ecd6b03006f40e8da4d5f2 (patch) | |
tree | 5a0d09b49272e510d289483b52f991820d2a37cc /tests/system/shared | |
parent | 9f46078afea181dda723f15de7f2d7f9fc5c303c (diff) | |
parent | 746c5d886395f66d3f7af1461555a75300201db6 (diff) | |
download | qt-creator-236ea9efb912c90cf3ecd6b03006f40e8da4d5f2.tar.gz |
Merge remote-tracking branch 'origin/3.0'
Conflicts:
share/qtcreator/debugger/dumper.cpp
share/qtcreator/debugger/dumper_p.h
share/qtcreator/debugger/test/main.cpp
src/plugins/debugger/gdb/classicgdbengine.cpp
src/plugins/debugger/gdb/pythongdbengine.cpp
src/plugins/debugger/lldblib/guest/lldbengineguest.cpp
src/plugins/debugger/lldblib/guest/lldbengineguest.h
src/plugins/debugger/lldblib/guest/main.cpp
src/plugins/debugger/lldblib/ipcengineguest.cpp
src/plugins/debugger/lldblib/ipcengineguest.h
src/plugins/debugger/lldblib/ipcenginehost.cpp
src/plugins/debugger/lldblib/ipcenginehost.h
src/plugins/debugger/lldblib/lldbenginehost.cpp
src/plugins/debugger/lldblib/lldboptionspage.cpp
src/plugins/qbsprojectmanager/qbsstep.cpp
src/plugins/qbsprojectmanager/qbsstep.h
src/plugins/qmlprofiler/canvas/qdeclarativecanvas.cpp
src/plugins/qmlprofiler/canvas/qdeclarativecanvas_p.h
src/plugins/qmlprofiler/canvas/qdeclarativecontext2d.cpp
src/plugins/qmlprofiler/canvas/qdeclarativecontext2d_p.h
src/plugins/qmlprofiler/canvas/qmlprofilercanvas.cpp
src/plugins/qnx/blackberrycheckdevmodestep.cpp
src/plugins/qtsupport/debugginghelper.cpp
Change-Id: Ie9fd0a885fb6264a6a8a72daee071b75bcbd2e9d
Diffstat (limited to 'tests/system/shared')
-rw-r--r-- | tests/system/shared/build_utils.py | 17 | ||||
-rw-r--r-- | tests/system/shared/classes.py | 2 | ||||
-rw-r--r-- | tests/system/shared/debugger.py | 2 | ||||
-rw-r--r-- | tests/system/shared/editor_utils.py | 2 | ||||
-rw-r--r-- | tests/system/shared/fs_utils.py | 2 | ||||
-rw-r--r-- | tests/system/shared/hook_utils.py | 2 | ||||
-rw-r--r-- | tests/system/shared/project.py | 30 | ||||
-rw-r--r-- | tests/system/shared/project_explorer.py | 4 | ||||
-rw-r--r-- | tests/system/shared/qtcreator.py | 2 | ||||
-rwxr-xr-x | tests/system/shared/suites_qtta.py | 2 | ||||
-rw-r--r-- | tests/system/shared/utils.py | 8 | ||||
-rw-r--r-- | tests/system/shared/workarounds.py | 2 |
12 files changed, 39 insertions, 36 deletions
diff --git a/tests/system/shared/build_utils.py b/tests/system/shared/build_utils.py index 5a34aac4a3..83188d5ed7 100644 --- a/tests/system/shared/build_utils.py +++ b/tests/system/shared/build_utils.py @@ -1,6 +1,6 @@ ############################################################################# ## -## Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +## Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). ## Contact: http://www.qt-project.org/legal ## ## This file is part of Qt Creator. @@ -35,10 +35,6 @@ installedSignalHandlers = {} overridenInstallLazySignalHandlers = False # flag to indicate whether a tasks file should be created when building ends with errors createTasksFileOnError = True -# currently used directory for tasks files -tasksFileDir = None -# counter for written tasks files -tasksFileCount = 0 # call this function to override installLazySignalHandler() def overrideInstallLazySignalHandler(): @@ -117,9 +113,14 @@ def dumpBuildIssues(listModel): range(Qt.UserRole, Qt.UserRole + 6))]) return issueDump +# counter for written tasks files +tasksFileCount = 0 + # helper method that writes a tasks file def createTasksFile(buildIssues): - global tasksFileDir, tasksFileCount + # currently used directory for tasks files + tasksFileDir = None + global tasksFileCount if tasksFileDir == None: tasksFileDir = os.getcwd() + "/tasks" tasksFileDir = os.path.abspath(tasksFileDir) @@ -184,8 +185,8 @@ def iterateBuildConfigs(kitCount, filter = ""): def selectBuildConfig(targetCount, currentTarget, configName): switchViewTo(ViewConstants.PROJECTS) switchToBuildOrRunSettingsFor(targetCount, currentTarget, ProjectSettings.BUILD) - if selectFromCombo(":scrollArea.Edit build configuration:_QComboBox", configName): - progressBarWait(30000) + selectFromCombo(":scrollArea.Edit build configuration:_QComboBox", configName) + progressBarWait(30000) return getQtInformationForBuildSettings(targetCount, True, ViewConstants.EDIT) # This will not trigger a rebuild. If needed, caller has to do this. diff --git a/tests/system/shared/classes.py b/tests/system/shared/classes.py index 7296038d13..5a7e84bbf0 100644 --- a/tests/system/shared/classes.py +++ b/tests/system/shared/classes.py @@ -1,6 +1,6 @@ ############################################################################# ## -## Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +## Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). ## Contact: http://www.qt-project.org/legal ## ## This file is part of Qt Creator. diff --git a/tests/system/shared/debugger.py b/tests/system/shared/debugger.py index d4fbfbd9c0..855fe04164 100644 --- a/tests/system/shared/debugger.py +++ b/tests/system/shared/debugger.py @@ -1,6 +1,6 @@ ############################################################################# ## -## Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +## Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). ## Contact: http://www.qt-project.org/legal ## ## This file is part of Qt Creator. diff --git a/tests/system/shared/editor_utils.py b/tests/system/shared/editor_utils.py index eca3162e57..76fab76af7 100644 --- a/tests/system/shared/editor_utils.py +++ b/tests/system/shared/editor_utils.py @@ -1,6 +1,6 @@ ############################################################################# ## -## Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +## Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). ## Contact: http://www.qt-project.org/legal ## ## This file is part of Qt Creator. diff --git a/tests/system/shared/fs_utils.py b/tests/system/shared/fs_utils.py index 8a5c8e3451..72b2f1a879 100644 --- a/tests/system/shared/fs_utils.py +++ b/tests/system/shared/fs_utils.py @@ -1,6 +1,6 @@ ############################################################################# ## -## Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +## Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). ## Contact: http://www.qt-project.org/legal ## ## This file is part of Qt Creator. diff --git a/tests/system/shared/hook_utils.py b/tests/system/shared/hook_utils.py index f1f64dd9ea..82e00bd9f0 100644 --- a/tests/system/shared/hook_utils.py +++ b/tests/system/shared/hook_utils.py @@ -1,6 +1,6 @@ ############################################################################# ## -## Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +## Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). ## Contact: http://www.qt-project.org/legal ## ## This file is part of Qt Creator. diff --git a/tests/system/shared/project.py b/tests/system/shared/project.py index 0b784304f9..634269cc6d 100644 --- a/tests/system/shared/project.py +++ b/tests/system/shared/project.py @@ -1,6 +1,6 @@ ############################################################################# ## -## Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +## Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). ## Contact: http://www.qt-project.org/legal ## ## This file is part of Qt Creator. @@ -30,13 +30,8 @@ import __builtin__ import re -processStarted = False processExited = False -def __handleProcessStarted__(*args): - global processStarted - processStarted = True - def __handleProcessExited__(*args): global processExited processExited = True @@ -388,6 +383,16 @@ def __chooseTargets__(targets=Targets.DESKTOP_474_GCC, availableTargets=None): test.warning("Target '%s' is not set up correctly." % Targets.getStringForTarget(current)) return checkedTargets +def waitForProcessStarted(): + outputButton = waitForObject(":Qt Creator_AppOutput_Core::Internal::OutputPaneToggleButton") + if not waitFor("outputButton.checked", 10000): + ensureChecked(outputButton) + waitFor("object.exists(':Qt Creator.ReRun_QToolButton')", 20000) + reRunButton = findObject(":Qt Creator.ReRun_QToolButton") + waitFor("object.exists(':Qt Creator.Stop_QToolButton')", 20000) + stopButton = findObject(":Qt Creator.Stop_QToolButton") + return waitFor("not reRunButton.enabled and stopButton.enabled", 10000) + # run and close an application # withHookInto - if set to True the function tries to attach to the sub-process instead of simply pressing Stop inside Creator # executable - must be defined when using hook-into @@ -399,22 +404,21 @@ def __chooseTargets__(targets=Targets.DESKTOP_474_GCC, availableTargets=None): # by yourself (or use the function parameter) # ATTENTION! Make sure this function won't fail and the sub-process will end when the function returns def runAndCloseApp(withHookInto=False, executable=None, port=None, function=None, sType=None, userDefinedType=None): - global processStarted, processExited - processStarted = processExited = False + global processExited + processExited = False overrideInstallLazySignalHandler() - installLazySignalHandler("{type='QProcess'}", "started()", "__handleProcessStarted__") installLazySignalHandler("{type='QProcess'}", "finished(int,QProcess::ExitStatus)", "__handleProcessExited__") runButton = waitForObject(":*Qt Creator.Run_Core::Internal::FancyToolButton") clickButton(runButton) if sType != SubprocessType.QT_QUICK_UI: waitForSignal("{type='ProjectExplorer::BuildManager' unnamed='1'}", "buildQueueFinished(bool)", 300000) buildSucceeded = checkLastBuild() + ensureChecked(waitForObject(":Qt Creator_AppOutput_Core::Internal::OutputPaneToggleButton")) if not buildSucceeded: test.fatal("Build inside run wasn't successful - leaving test") invokeMenuItem("File", "Exit") return False - waitFor("processStarted==True", 10000) - if not processStarted: + if not waitForProcessStarted(): test.fatal("Couldn't start application - leaving test") invokeMenuItem("File", "Exit") return False @@ -489,11 +493,9 @@ def __closeSubprocessByHookingInto__(executable, port, function, sType, userDefT "unnamed='1' visible='1'} type='QComboBox' unnamed='1' " "visible='1'}"), selectConfig) switchViewTo(ViewConstants.EDIT) - global processStarted - processStarted = False runButton = waitForObject(":*Qt Creator.Run_Core::Internal::FancyToolButton") clickButton(runButton) - if not waitFor("processStarted == True", 10000): + if not waitForProcessStarted(): test.fatal("Something seems to be really wrong.", "Application output:" % str(output.plainText)) return False diff --git a/tests/system/shared/project_explorer.py b/tests/system/shared/project_explorer.py index 23e8327bbf..528167c045 100644 --- a/tests/system/shared/project_explorer.py +++ b/tests/system/shared/project_explorer.py @@ -1,6 +1,6 @@ ############################################################################# ## -## Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +## Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). ## Contact: http://www.qt-project.org/legal ## ## This file is part of Qt Creator. @@ -185,7 +185,7 @@ def getQtInformationForQmlProject(): waitForObjectItem(":Options_QListView", "Build & Run") clickItem(":Options_QListView", "Build & Run", 14, 15, 0, Qt.LeftButton) clickOnTab(":Options.qt_tabwidget_tabbar_QTabBar", "Kits") - targetsTreeView = waitForObject(":Kits_Or_Compilers_QTreeView") + targetsTreeView = waitForObject(":BuildAndRun_QTreeView") if not __selectTreeItemOnBuildAndRun__(targetsTreeView, "%s(\s\(default\))?" % kit, True): test.fatal("Found no matching kit - this shouldn't happen.") clickButton(waitForObject(":Options.Cancel_QPushButton")) diff --git a/tests/system/shared/qtcreator.py b/tests/system/shared/qtcreator.py index d19a1935db..76e947c026 100644 --- a/tests/system/shared/qtcreator.py +++ b/tests/system/shared/qtcreator.py @@ -1,6 +1,6 @@ ############################################################################# ## -## Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +## Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). ## Contact: http://www.qt-project.org/legal ## ## This file is part of Qt Creator. diff --git a/tests/system/shared/suites_qtta.py b/tests/system/shared/suites_qtta.py index f492206fb3..01ed84a0da 100755 --- a/tests/system/shared/suites_qtta.py +++ b/tests/system/shared/suites_qtta.py @@ -1,6 +1,6 @@ ############################################################################# ## -## Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +## Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). ## Contact: http://www.qt-project.org/legal ## ## This file is part of Qt Creator. diff --git a/tests/system/shared/utils.py b/tests/system/shared/utils.py index 073aa981e5..0d7c5f2050 100644 --- a/tests/system/shared/utils.py +++ b/tests/system/shared/utils.py @@ -1,6 +1,6 @@ ############################################################################# ## -## Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +## Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). ## Contact: http://www.qt-project.org/legal ## ## This file is part of Qt Creator. @@ -393,7 +393,7 @@ def getConfiguredKits(): return treeWidget.currentItem().text(0) # end of internal function for iterateQtVersions def __setQtVersionForKit__(kit, kitName, kitsQtVersionName): - treeView = waitForObject(":Kits_Or_Compilers_QTreeView") + treeView = waitForObject(":BuildAndRun_QTreeView") clickItem(treeView, kit, 5, 5, 0, Qt.LeftButton) qtVersionStr = str(waitForObject(":Kits_QtVersion_QComboBox").currentText) kitsQtVersionName[kitName] = qtVersionStr @@ -446,7 +446,7 @@ def regexVerify(text, expectedTexts): def checkDebuggingLibrary(kitIDs): def __getQtVersionForKit__(kit, kitName): - treeView = waitForObject(":Kits_Or_Compilers_QTreeView") + treeView = waitForObject(":BuildAndRun_QTreeView") clickItem(treeView, kit, 5, 5, 0, Qt.LeftButton) return str(waitForObject(":Kits_QtVersion_QComboBox").currentText) # end of internal function for iterate kits @@ -598,7 +598,7 @@ def iterateKits(keepOptionsOpen=False, alreadyOnOptionsDialog=False, waitForObjectItem(":Options_QListView", "Build & Run") clickItem(":Options_QListView", "Build & Run", 14, 15, 0, Qt.LeftButton) clickOnTab(":Options.qt_tabwidget_tabbar_QTabBar", "Kits") - treeView = waitForObject(":Kits_Or_Compilers_QTreeView") + treeView = waitForObject(":BuildAndRun_QTreeView") model = treeView.model() test.compare(model.rowCount(), 2, "Verifying expected target section count") autoDetected = model.index(0, 0) diff --git a/tests/system/shared/workarounds.py b/tests/system/shared/workarounds.py index 509e4291d8..05a413eb57 100644 --- a/tests/system/shared/workarounds.py +++ b/tests/system/shared/workarounds.py @@ -1,6 +1,6 @@ ############################################################################# ## -## Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +## Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). ## Contact: http://www.qt-project.org/legal ## ## This file is part of Qt Creator. |