aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tests/system/suite_general/tst_rename_file/test.py19
1 files changed, 14 insertions, 5 deletions
diff --git a/tests/system/suite_general/tst_rename_file/test.py b/tests/system/suite_general/tst_rename_file/test.py
index 413e0385b4..7d846d3013 100644
--- a/tests/system/suite_general/tst_rename_file/test.py
+++ b/tests/system/suite_general/tst_rename_file/test.py
@@ -87,14 +87,16 @@ def renameFile(projectDir, proFile, branch, oldname, newname):
oldFilePath = os.path.join(projectDir, oldname)
newFilePath = os.path.join(projectDir, newname)
oldFileText = readFile(oldFilePath)
- itemText = branch + "." + oldname.replace(".", "\\.")
+ oldItemText = branch + "." + oldname.replace(".", "\\.")
+ newItemText = branch + "." + newname.replace(".", "\\.")
treeview = waitForObject(":Qt Creator_Utils::NavigationTreeView")
try:
- openItemContextMenu(treeview, itemText, 5, 5, 0)
+ openItemContextMenu(treeview, oldItemText, 5, 5, 0)
except:
- itemWithWildcard = addBranchWildcardToRoot(itemText)
- waitForObjectItem(treeview, itemWithWildcard, 10000)
- openItemContextMenu(treeview, itemWithWildcard, 5, 5, 0)
+ oldItemText = addBranchWildcardToRoot(oldItemText)
+ newItemText = addBranchWildcardToRoot(newItemText)
+ waitForObjectItem(treeview, oldItemText, 10000)
+ openItemContextMenu(treeview, oldItemText, 5, 5, 0)
if oldname.lower().endswith(".qrc"):
menu = ":Qt Creator.Project.Menu.Folder_QMenu"
else:
@@ -130,6 +132,13 @@ def renameFile(projectDir, proFile, branch, oldname, newname):
test.verify(oldname not in os.listdir(projectDir),
"Verify that file with old name does not exist: %s" % oldFilePath)
+ if newItemText.endswith("\\.qml"):
+ newItemText = newItemText.replace(".Other files.", ".QML.")
+ else:
+ newItemText = newItemText.replace(".QML.", ".Other files.")
+ waitForObjectItem(treeview, newItemText)
+
+
def safeReadFile(filename):
text = ""
while text == "":