diff options
author | Robert Loehning <robert.loehning@digia.com> | 2013-09-25 15:06:43 +0200 |
---|---|---|
committer | Robert Loehning <robert.loehning@digia.com> | 2013-09-25 17:04:49 +0200 |
commit | 65f05881963b2d54d9975d8ed27001813e1452f0 (patch) | |
tree | 763903729ce99b749be892576f3510ecc557a147 /tests | |
parent | 160bd09622015e25613ca752a2ed0c5fc68c2b98 (diff) | |
download | qt-creator-65f05881963b2d54d9975d8ed27001813e1452f0.tar.gz |
Squish: Stabilize suite_QMLS
Change-Id: I2194054c9c87eeff3b039b34dc4498f5cb0a19e2
Reviewed-by: Christian Stenger <christian.stenger@digia.com>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/system/suite_QMLS/tst_QMLS05/test.py | 6 | ||||
-rw-r--r-- | tests/system/suite_QMLS/tst_QMLS06/test.py | 6 | ||||
-rw-r--r-- | tests/system/suite_QMLS/tst_QMLS07/test.py | 6 |
3 files changed, 15 insertions, 3 deletions
diff --git a/tests/system/suite_QMLS/tst_QMLS05/test.py b/tests/system/suite_QMLS/tst_QMLS05/test.py index 008fb92314..926b70936b 100644 --- a/tests/system/suite_QMLS/tst_QMLS05/test.py +++ b/tests/system/suite_QMLS/tst_QMLS05/test.py @@ -47,7 +47,11 @@ def main(): invokeMenuItem("File", "Save All") # activate menu and apply 'Refactoring - Split initializer' numLinesExpected = len(str(editorArea.plainText).splitlines()) + 4 - invokeContextMenuItem(editorArea, "Refactoring", "Split Initializer") + try: + invokeContextMenuItem(editorArea, "Refactoring", "Split Initializer") + except: + # If menu item is disabled it needs to reopen the menu for updating + invokeContextMenuItem(editorArea, "Refactoring", "Split Initializer") # wait until refactoring ended waitFor("len(str(editorArea.plainText).splitlines()) == numLinesExpected", 5000) # verify if refactoring was properly applied - each part on separate line diff --git a/tests/system/suite_QMLS/tst_QMLS06/test.py b/tests/system/suite_QMLS/tst_QMLS06/test.py index 8c998e8fa6..7989883b7d 100644 --- a/tests/system/suite_QMLS/tst_QMLS06/test.py +++ b/tests/system/suite_QMLS/tst_QMLS06/test.py @@ -41,7 +41,11 @@ def main(): invokeMenuItem("File", "Save All") # invoke Refactoring - Wrap Component in Loader numLinesExpected = len(str(editorArea.plainText).splitlines()) + 10 - invokeContextMenuItem(editorArea, "Refactoring", "Wrap Component in Loader") + try: + invokeContextMenuItem(editorArea, "Refactoring", "Wrap Component in Loader") + except: + # If menu item is disabled it needs to reopen the menu for updating + invokeContextMenuItem(editorArea, "Refactoring", "Wrap Component in Loader") # wait until refactoring ended waitFor("len(str(editorArea.plainText).splitlines()) >= numLinesExpected", 5000) # verify if refactoring was properly applied diff --git a/tests/system/suite_QMLS/tst_QMLS07/test.py b/tests/system/suite_QMLS/tst_QMLS07/test.py index f3b118f841..5f942cfa44 100644 --- a/tests/system/suite_QMLS/tst_QMLS07/test.py +++ b/tests/system/suite_QMLS/tst_QMLS07/test.py @@ -40,7 +40,11 @@ def main(): invokeMenuItem("File", "Save All") # invoke Refactoring - Add a message suppression comment. numLinesExpected = len(str(editorArea.plainText).splitlines()) + 1 - invokeContextMenuItem(editorArea, "Refactoring", "Add a Comment to Suppress This Message") + try: + invokeContextMenuItem(editorArea, "Refactoring", "Add a Comment to Suppress This Message") + except: + # If menu item is disabled it needs to reopen the menu for updating + invokeContextMenuItem(editorArea, "Refactoring", "Add a Comment to Suppress This Message") # wait until refactoring ended waitFor("len(str(editorArea.plainText).splitlines()) >= numLinesExpected", 5000) # verify if refactoring was properly applied |