diff options
author | Robert Löhning <robert.loehning@qt.io> | 2021-10-29 22:57:07 +0200 |
---|---|---|
committer | Robert Löhning <robert.loehning@qt.io> | 2022-01-28 10:59:39 +0000 |
commit | 4980f71dd5d800a69e38264a64f1d103d7c156ec (patch) | |
tree | efbed208cca44de487d0754ac1d1b10fe1def7c2 | |
parent | 557489c3fcb930885f9129cdd76047de1852b4da (diff) |
Squish: Update tests which use "Rename Symbol Under Cursor"
When using this on open files, Creator used to make the changes
but not save the file. Creator 6 now also saves the file unless
it already contained other changes. Because the file is being
saved immediately, "Save All" and "Revert to Saved" cannot be
used in this situation anymore.
Change-Id: I0b8a58d998c54ccceae6d178b2c7a6f6182c7ad0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
-rw-r--r-- | tests/system/suite_editors/tst_qml_editor/test.py | 1 | ||||
-rw-r--r-- | tests/system/suite_editors/tst_rename_macros/test.py | 5 |
2 files changed, 3 insertions, 3 deletions
diff --git a/tests/system/suite_editors/tst_qml_editor/test.py b/tests/system/suite_editors/tst_qml_editor/test.py index c26207ea6e..e75db75893 100644 --- a/tests/system/suite_editors/tst_qml_editor/test.py +++ b/tests/system/suite_editors/tst_qml_editor/test.py @@ -87,7 +87,6 @@ def testRenameId(): formerTxt = editor.plainText originalText = originalTexts.get(file).replace("mainView", "renamedView") test.compare(originalText,formerTxt, "Comparing %s" % file.replace("Core.","").replace("\\","")) - invokeMenuItem("File","Save All") def __invokeFindUsage__(filename, line, additionalKeyPresses, expectedCount): openDocument(focusDocumentPath % filename) diff --git a/tests/system/suite_editors/tst_rename_macros/test.py b/tests/system/suite_editors/tst_rename_macros/test.py index 491cc3bd20..f1111f8583 100644 --- a/tests/system/suite_editors/tst_rename_macros/test.py +++ b/tests/system/suite_editors/tst_rename_macros/test.py @@ -46,6 +46,8 @@ def main(): expectedHeaderName=headerName) if not testRenameMacroAfterSourceMoving(): return + # save and exit + invokeMenuItem("File", "Save All") invokeMenuItem("File", "Exit") def testRenameMacroAfterSourceModification(): @@ -156,8 +158,7 @@ def revertChanges(files): simpleName = simpleFileName(f) if openDocument(f): try: - invokeMenuItem('File', 'Revert "%s" to Saved' % simpleName) - clickButton(waitForObject(":Revert to Saved.Proceed_QPushButton")) + invokeMenuItem('Edit', 'Undo') test.log("Reverted changes inside %s" % simpleName) except: test.warning("File '%s' cannot be reverted." % simpleName, |