aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorRobert Loehning <robert.loehning@qt.io>2018-03-13 23:03:33 +0100
committerRobert Loehning <robert.loehning@qt.io>2018-03-15 14:09:50 +0000
commitfad75a3d566f730731fd715a77649ef8ebd57892 (patch)
treef1a729e2629b67d63bf0d0145c9decae8d2dd665 /tests
parent454c7f83ff660fafa77488a4d33a020b9982f1cc (diff)
Squish: Update tst_rename_file
Creator only selects the filename now, the extension will be left unchanged by default. Task-number: QTCREATORBUG-20057 Change-Id: I66bbbb5b95e1d487c2087efa596a87a240721e44 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Diffstat (limited to 'tests')
-rw-r--r--tests/system/suite_general/tst_rename_file/test.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/tests/system/suite_general/tst_rename_file/test.py b/tests/system/suite_general/tst_rename_file/test.py
index ee55e9c2b4..7bf2c882ea 100644
--- a/tests/system/suite_general/tst_rename_file/test.py
+++ b/tests/system/suite_general/tst_rename_file/test.py
@@ -101,8 +101,12 @@ def renameFile(projectDir, proFile, branch, oldname, newname):
else:
menu = ":Qt Creator.Project.Menu.File_QMenu"
activateItem(waitForObjectItem(menu, "Rename..."))
- type(waitForObject(":Qt Creator_Utils::NavigationTreeView::QExpandingLineEdit"), newname)
- type(waitForObject(":Qt Creator_Utils::NavigationTreeView::QExpandingLineEdit"), "<Return>")
+ replaceEdit = waitForObject(":Qt Creator_Utils::NavigationTreeView::QExpandingLineEdit")
+ if not (oldname.lower().endswith(".qrc") and JIRA.isBugStillOpen(20057)):
+ test.compare(replaceEdit.selectedText, oldname.rsplit(".", 1)[0],
+ "Only the filename without the extension is selected?")
+ replaceEditorContent(replaceEdit, newname)
+ type(replaceEdit, "<Return>")
test.verify(waitFor("os.path.exists(newFilePath)", 1000),
"Verify that file with new name exists: %s" % newFilePath)
test.compare(readFile(newFilePath), oldFileText,