Commit 8eefc344 authored by Robert Loehning's avatar Robert Loehning
Browse files

Squish: Update paths to QML files

Reaction to 96367b62



Change-Id: I9651f9cac2b6c48158fa9094ef86ef04460e8a16
Reviewed-by: default avatarChristian Stenger <christian.stenger@digia.com>
parent 96367b62
...@@ -37,7 +37,7 @@ def startQtCreatorWithNewAppAtQMLEditor(projectDir, projectName, line = None): ...@@ -37,7 +37,7 @@ def startQtCreatorWithNewAppAtQMLEditor(projectDir, projectName, line = None):
# create qt quick application # create qt quick application
createNewQtQuickApplication(projectDir, projectName) createNewQtQuickApplication(projectDir, projectName)
# open qml file # open qml file
qmlFile = projectName + ".Resources.qml\.qrc./.qml/main\\.qml" qmlFile = projectName + ".Resources.qml\.qrc./.main\\.qml"
if not openDocument(qmlFile): if not openDocument(qmlFile):
test.fatal("Could not open %s" % qmlFile) test.fatal("Could not open %s" % qmlFile)
invokeMenuItem("File", "Exit") invokeMenuItem("File", "Exit")
......
...@@ -56,7 +56,7 @@ def main(): ...@@ -56,7 +56,7 @@ def main():
test.passes("Refactoring was properly applied in source file") test.passes("Refactoring was properly applied in source file")
else: else:
test.fail("Refactoring of Text to MyComponent failed in source file. Content of editor:\n%s" % codeText) test.fail("Refactoring of Text to MyComponent failed in source file. Content of editor:\n%s" % codeText)
myCompTE = "SampleApp.Resources.qml\\.qrc./.qml/MyComponent\\.qml" myCompTE = "SampleApp.Resources.qml\\.qrc./.MyComponent\\.qml"
# there should be new QML file generated with name "MyComponent.qml" # there should be new QML file generated with name "MyComponent.qml"
try: try:
waitForObjectItem(":Qt Creator_Utils::NavigationTreeView", myCompTE, 3000) waitForObjectItem(":Qt Creator_Utils::NavigationTreeView", myCompTE, 3000)
...@@ -86,6 +86,6 @@ def main(): ...@@ -86,6 +86,6 @@ def main():
#save and exit #save and exit
invokeMenuItem("File", "Save All") invokeMenuItem("File", "Save All")
# check if new file was created in file system # check if new file was created in file system
test.verify(os.path.exists(os.path.join(projectDir, "SampleApp", "qml", "MyComponent.qml")), test.verify(os.path.exists(os.path.join(projectDir, "SampleApp", "MyComponent.qml")),
"Verifying if MyComponent.qml exists in file system after save") "Verifying if MyComponent.qml exists in file system after save")
invokeMenuItem("File", "Exit") invokeMenuItem("File", "Exit")
...@@ -38,7 +38,7 @@ def main(): ...@@ -38,7 +38,7 @@ def main():
# create qt quick application # create qt quick application
createNewQtQuickApplication(tempDir(), "SampleApp") createNewQtQuickApplication(tempDir(), "SampleApp")
# create syntax error in qml file # create syntax error in qml file
openDocument("SampleApp.Resources.qml\.qrc./.qml/main\\.qml") openDocument("SampleApp.Resources.qml\.qrc./.main\\.qml")
if not appendToLine(waitForObject(":Qt Creator_QmlJSEditor::QmlJSTextEditorWidget"), "Text {", "SyntaxError"): if not appendToLine(waitForObject(":Qt Creator_QmlJSEditor::QmlJSTextEditorWidget"), "Text {", "SyntaxError"):
invokeMenuItem("File", "Exit") invokeMenuItem("File", "Exit")
return return
......
...@@ -48,14 +48,14 @@ def main(): ...@@ -48,14 +48,14 @@ def main():
'onTriggered: console.log("Break here")']) 'onTriggered: console.log("Break here")'])
invokeMenuItem("File", "Save All") invokeMenuItem("File", "Save All")
filesAndLines = [ filesAndLines = [
{ "%s.Resources.qml\.qrc./.qml/main\\.qml" % projectName : 'onTriggered.*' }, { "%s.Resources.qml\.qrc./.main\\.qml" % projectName : 'onTriggered.*' },
{ "%s.Sources.main\\.cpp" % projectName : "viewer.setOrientation\\(.+\\);" } { "%s.Sources.main\\.cpp" % projectName : "viewer.setOrientation\\(.+\\);" }
] ]
test.log("Setting breakpoints") test.log("Setting breakpoints")
result = setBreakpointsForCurrentProject(filesAndLines) result = setBreakpointsForCurrentProject(filesAndLines)
if result: if result:
expectedBreakpointsOrder = [{os.path.join(workingDir, projectName, "main.cpp"):10}, expectedBreakpointsOrder = [{os.path.join(workingDir, projectName, "main.cpp"):10},
{os.path.join(workingDir, projectName, "qml", "main.qml"):10}] {os.path.join(workingDir, projectName, "main.qml"):10}]
# Only use 4.7.4 to work around QTBUG-25187 # Only use 4.7.4 to work around QTBUG-25187
availableConfigs = iterateBuildConfigs(len(checkedTargets), "Debug") availableConfigs = iterateBuildConfigs(len(checkedTargets), "Debug")
progressBarWait() progressBarWait()
......
...@@ -45,7 +45,7 @@ def main(): ...@@ -45,7 +45,7 @@ def main():
invokeMenuItem("File", "Exit") invokeMenuItem("File", "Exit")
def prepareQmlFile(): def prepareQmlFile():
if not openDocument("untitled.Resources.qml\.qrc./.qml/main\\.qml"): if not openDocument("untitled.Resources.qml\.qrc./.main\\.qml"):
test.fatal("Could not open main.qml") test.fatal("Could not open main.qml")
return None return None
editor = waitForObject(":Qt Creator_QmlJSEditor::QmlJSTextEditorWidget") editor = waitForObject(":Qt Creator_QmlJSEditor::QmlJSTextEditorWidget")
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment