summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/system/shared/build_utils.py13
-rwxr-xr-xtests/system/suite_CCOM/tst_CCOM01/test.py2
-rw-r--r--tests/system/suite_SCOM/tst_SCOM01/test.py2
-rw-r--r--tests/system/suite_SCOM/tst_SCOM05/test.py2
4 files changed, 11 insertions, 8 deletions
diff --git a/tests/system/shared/build_utils.py b/tests/system/shared/build_utils.py
index 370381b2be..c858333fde 100644
--- a/tests/system/shared/build_utils.py
+++ b/tests/system/shared/build_utils.py
@@ -80,15 +80,18 @@ def checkCompile():
ensureChecked(":Qt Creator_CompileOutput_Core::Internal::OutputPaneToggleButton")
output = waitForObject(":Qt Creator.Compile Output_Core::OutputWindow")
waitFor("len(str(output.plainText))>0",5000)
- success = str(output.plainText).endswith("exited normally.")
- if success:
+ if compileSucceeded(output.plainText):
if os.getenv("SYSTEST_DEBUG") == "1":
test.log("Compile Output:\n%s" % output.plainText)
- else:
- test.passes("Compile successful")
+ test.passes("Compile successful")
+ return True
else:
test.fail("Compile Output:\n%s" % output.plainText)
- return success
+ return False
+
+def compileSucceeded(compileOutput):
+ return None != re.match(".*exited normally\.\n\d\d:\d\d:\d\d: Elapsed time: "
+ "(\d:)?\d{2}:\d\d\.$", str(compileOutput), re.S)
# helper method that parses the Issues output and writes a tasks file
def createTasksFile(list):
diff --git a/tests/system/suite_CCOM/tst_CCOM01/test.py b/tests/system/suite_CCOM/tst_CCOM01/test.py
index 4c68038b97..7924e8c6b1 100755
--- a/tests/system/suite_CCOM/tst_CCOM01/test.py
+++ b/tests/system/suite_CCOM/tst_CCOM01/test.py
@@ -27,7 +27,7 @@ def main():
# verify build successful
ensureChecked(waitForObject(":Qt Creator_CompileOutput_Core::Internal::OutputPaneToggleButton"))
compileOutput = waitForObject(":Qt Creator.Compile Output_Core::OutputWindow")
- if not test.verify(str(compileOutput.plainText).endswith("exited normally."),
+ if not test.verify(compileSucceeded(compileOutput.plainText),
"Verifying building of existing complex qt application."):
test.log(compileOutput.plainText)
# exit
diff --git a/tests/system/suite_SCOM/tst_SCOM01/test.py b/tests/system/suite_SCOM/tst_SCOM01/test.py
index 75b33d92d6..b279fc5525 100644
--- a/tests/system/suite_SCOM/tst_SCOM01/test.py
+++ b/tests/system/suite_SCOM/tst_SCOM01/test.py
@@ -19,7 +19,7 @@ def main():
# check output if build successful
ensureChecked(waitForObject(":Qt Creator_CompileOutput_Core::Internal::OutputPaneToggleButton"))
compileOutput = waitForObject(":Qt Creator.Compile Output_Core::OutputWindow")
- if not test.verify(str(compileOutput.plainText).endswith("exited normally."),
+ if not test.verify(compileSucceeded(compileOutput.plainText),
"Verifying building of simple qt quick application."):
test.log(compileOutput.plainText)
# exit qt creator
diff --git a/tests/system/suite_SCOM/tst_SCOM05/test.py b/tests/system/suite_SCOM/tst_SCOM05/test.py
index affea39bcd..505c9ff0c7 100644
--- a/tests/system/suite_SCOM/tst_SCOM05/test.py
+++ b/tests/system/suite_SCOM/tst_SCOM05/test.py
@@ -44,7 +44,7 @@ def main():
ensureChecked(waitForObject(":Qt Creator_CompileOutput_Core::Internal::OutputPaneToggleButton"))
outputLog = str(waitForObject(":Qt Creator.Compile Output_Core::OutputWindow").plainText)
# verify that project was built successfully
- test.verify(outputLog.endswith("exited normally."),
+ test.verify(compileSucceeded(outputLog),
"Verifying building of simple qt quick application while multiple projects are open.")
# verify that proper project (project 2) was build
test.verify(projectName2 in outputLog and projectName1 not in outputLog,