aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorRobert Loehning <robert.loehning@qt.io>2018-08-03 16:10:45 +0200
committerRobert Loehning <robert.loehning@qt.io>2018-08-07 09:25:05 +0000
commit2c6a57be9c6603eac37ab4755b738c21c3f03081 (patch)
tree1ba1b8cddb5d14d18e98a4d0a84e2868fe259bbb /tests
parent43c2f366225af35d9d3a08c545253c754112424b (diff)
Squish: Move imports of "os", "re" and "sys" into shared class
Change-Id: I349cb255b8fa6f96e32d5dacb3c9b58ddeb76897 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Diffstat (limited to 'tests')
-rw-r--r--tests/system/shared/build_utils.py2
-rw-r--r--tests/system/shared/editor_utils.py2
-rw-r--r--tests/system/shared/project.py3
-rw-r--r--tests/system/shared/project_explorer.py2
-rw-r--r--tests/system/shared/qtcreator.py1
-rw-r--r--tests/system/shared/utils.py2
-rw-r--r--tests/system/shared/workarounds.py1
-rw-r--r--tests/system/suite_HELP/tst_HELP04/test.py1
-rw-r--r--tests/system/suite_debugger/tst_qml_locals/Tree.py2
-rw-r--r--tests/system/suite_general/tst_default_settings/test.py2
10 files changed, 1 insertions, 17 deletions
diff --git a/tests/system/shared/build_utils.py b/tests/system/shared/build_utils.py
index 0aaab2ac33..ee9037557f 100644
--- a/tests/system/shared/build_utils.py
+++ b/tests/system/shared/build_utils.py
@@ -23,8 +23,6 @@
#
############################################################################
-import re;
-
def getBuildIssues():
ensureChecked(":Qt Creator_Issues_Core::Internal::OutputPaneToggleButton")
model = waitForObject(":Qt Creator.Issues_QListView").model()
diff --git a/tests/system/shared/editor_utils.py b/tests/system/shared/editor_utils.py
index df3f7d37ea..9b391b4497 100644
--- a/tests/system/shared/editor_utils.py
+++ b/tests/system/shared/editor_utils.py
@@ -23,8 +23,6 @@
#
############################################################################
-import re;
-
# places the cursor inside the given editor into the given line
# (leading and trailing whitespaces are ignored!)
# and goes to the end of the line
diff --git a/tests/system/shared/project.py b/tests/system/shared/project.py
index bd79846102..ac6bec0d38 100644
--- a/tests/system/shared/project.py
+++ b/tests/system/shared/project.py
@@ -23,9 +23,6 @@
#
############################################################################
-import __builtin__
-import re
-
def openQbsProject(projectPath):
cleanUpUserFiles(projectPath)
invokeMenuItem("File", "Open File or Project...")
diff --git a/tests/system/shared/project_explorer.py b/tests/system/shared/project_explorer.py
index 2ad9a32957..3c7ed2535d 100644
--- a/tests/system/shared/project_explorer.py
+++ b/tests/system/shared/project_explorer.py
@@ -23,8 +23,6 @@
#
############################################################################
-import re;
-
# this function switches the MainWindow of creator to the specified view
def switchViewTo(view):
# make sure that no tooltip is shown, so move the mouse away and wait until all disappear
diff --git a/tests/system/shared/qtcreator.py b/tests/system/shared/qtcreator.py
index c812ccd624..409be0fc30 100644
--- a/tests/system/shared/qtcreator.py
+++ b/tests/system/shared/qtcreator.py
@@ -24,6 +24,7 @@
############################################################################
import platform;
+import re;
import shutil;
import os;
import glob;
diff --git a/tests/system/shared/utils.py b/tests/system/shared/utils.py
index 097772769d..5bbec57458 100644
--- a/tests/system/shared/utils.py
+++ b/tests/system/shared/utils.py
@@ -457,7 +457,6 @@ def iterateQtVersions(keepOptionsOpen=False, alreadyOnOptionsDialog=False,
else:
currResult = additionalFunction(target, version, *argsForAdditionalFunc)
except:
- import sys
t,v,_ = sys.exc_info()
currResult = None
test.fatal("Function to additionally execute on Options Dialog could not be found or "
@@ -520,7 +519,6 @@ def iterateKits(keepOptionsOpen=False, alreadyOnOptionsDialog=False,
else:
currResult = additionalFunction(item, kitName, *argsForAdditionalFunc)
except:
- import sys
t,v,_ = sys.exc_info()
currResult = None
test.fatal("Function to additionally execute on Options Dialog could not be "
diff --git a/tests/system/shared/workarounds.py b/tests/system/shared/workarounds.py
index cb1cc0ba84..a74fbb5981 100644
--- a/tests/system/shared/workarounds.py
+++ b/tests/system/shared/workarounds.py
@@ -24,7 +24,6 @@
############################################################################
import urllib2
-import re
############ functions not related to issues tracked inside jira ############
diff --git a/tests/system/suite_HELP/tst_HELP04/test.py b/tests/system/suite_HELP/tst_HELP04/test.py
index 471df57378..e6ce7932d0 100644
--- a/tests/system/suite_HELP/tst_HELP04/test.py
+++ b/tests/system/suite_HELP/tst_HELP04/test.py
@@ -24,7 +24,6 @@
############################################################################
source("../../shared/qtcreator.py")
-import re
# test search in help mode and advanced search
searchKeywordDictionary={ "abundance":True, "deplmint":False, "QODBC":True, "bld":False }
diff --git a/tests/system/suite_debugger/tst_qml_locals/Tree.py b/tests/system/suite_debugger/tst_qml_locals/Tree.py
index 53063b2a8b..b4202de9e7 100644
--- a/tests/system/suite_debugger/tst_qml_locals/Tree.py
+++ b/tests/system/suite_debugger/tst_qml_locals/Tree.py
@@ -23,8 +23,6 @@
#
############################################################################
-import os
-
# Helper class to create a tree structure
class Tree:
def __init__(self, name=None, value=None, children=None):
diff --git a/tests/system/suite_general/tst_default_settings/test.py b/tests/system/suite_general/tst_default_settings/test.py
index bb75bf9b32..08b8cc2253 100644
--- a/tests/system/suite_general/tst_default_settings/test.py
+++ b/tests/system/suite_general/tst_default_settings/test.py
@@ -25,8 +25,6 @@
source("../../shared/qtcreator.py")
-import re
-
currentSelectedTreeItem = None
warningOrError = re.compile('<p><b>((Error|Warning).*?)</p>')