summaryrefslogtreecommitdiff
path: root/tests/system/suite_QMLS
diff options
context:
space:
mode:
authorChristian Stenger <christian.stenger@nokia.com>2012-09-10 14:40:12 +0200
committerChristian Stenger <christian.stenger@nokia.com>2012-09-12 17:22:39 +0200
commit77a6b71f72917939f2fd9c5e1915f8b0f5009949 (patch)
treec88edc6e4601ea06c0f70df483cfdac7bbaa21f9 /tests/system/suite_QMLS
parentf53ed6c4b3feca59a94d4f0de8b1a7411122e30e (diff)
downloadqt-creator-77a6b71f72917939f2fd9c5e1915f8b0f5009949.tar.gz
Squish: Use global objects.map from inside QMLS
Change-Id: I5c37408bc3a0e232d7f2a70e01db510725f99df1 Reviewed-by: Robert Loehning <robert.loehning@nokia.com>
Diffstat (limited to 'tests/system/suite_QMLS')
-rw-r--r--tests/system/suite_QMLS/objects.map26
-rw-r--r--tests/system/suite_QMLS/suite.conf2
-rw-r--r--tests/system/suite_QMLS/tst_QMLS01/test.py13
-rw-r--r--tests/system/suite_QMLS/tst_QMLS03/test.py4
4 files changed, 10 insertions, 35 deletions
diff --git a/tests/system/suite_QMLS/objects.map b/tests/system/suite_QMLS/objects.map
deleted file mode 100644
index 870e1b31ab..0000000000
--- a/tests/system/suite_QMLS/objects.map
+++ /dev/null
@@ -1,26 +0,0 @@
-:Add to Version Control.No_QPushButton {text='No' type='QPushButton' unnamed='1' visible='1' window=':Add to Version Control_QMessageBox'}
-:Add to Version Control_QMessageBox {type='QMessageBox' unnamed='1' visible='1' windowTitle='Add to Version Control'}
-:Behavior.Autocomplete common prefix_QCheckBox {container=':CppTools__Internal__CompletionSettingsPage.Behavior_QGroupBox' name='partiallyComplete' text='Autocomplete common prefix' type='QCheckBox' visible='1'}
-:Behavior.completionTrigger_QComboBox {container=':CppTools__Internal__CompletionSettingsPage.Behavior_QGroupBox' name='completionTrigger' type='QComboBox' visible='1'}
-:CppTools__Internal__CompletionSettingsPage.Behavior_QGroupBox {container=':qt_tabwidget_stackedwidget.CppTools__Internal__CompletionSettingsPage_QWidget' name='groupBox' title='Behavior' type='QGroupBox' visible='1'}
-:Dialog.OK_QPushButton {text='OK' type='QPushButton' unnamed='1' visible='1' window=':Dialog_QmlJSEditor::Internal::ComponentNameDialog'}
-:Dialog.componentNameEdit_QLineEdit {name='componentNameEdit' type='Utils::ClassNameValidatingLineEdit' visible='1' window=':Dialog_QmlJSEditor::Internal::ComponentNameDialog'}
-:Dialog_QmlJSEditor::Internal::ComponentNameDialog {name='QmlJSEditor__Internal__ComponentNameDialog' type='QmlJSEditor::Internal::ComponentNameDialog' visible='1' windowTitle='Move Component into Separate File'}
-:New Qt Quick Application.Add to version control:_QLabel {name='addToVersionControlLabel' text='Add to version control:' type='QLabel' visible='1'}
-:Next_QPushButton {name='__qt__passive_wizardbutton1' text~='(Next.*|Continue)' type='QPushButton' visible='1'}
-:Options.OK_QPushButton {text='OK' type='QPushButton' unnamed='1' visible='1' window=':Options_Core::Internal::SettingsDialog'}
-:Options.qt_tabwidget_stackedwidget_QStackedWidget {name='qt_tabwidget_stackedwidget' type='QStackedWidget' visible='1' window=':Options_Core::Internal::SettingsDialog'}
-:Options.qt_tabwidget_tabbar_QTabBar {name='qt_tabwidget_tabbar' type='QTabBar' visible='1' window=':Options_Core::Internal::SettingsDialog'}
-:Options_Core::Internal::SettingsDialog {type='Core::Internal::SettingsDialog' unnamed='1' visible='1' windowTitle~='(Options|Preferences)'}
-:Options_QListView {type='QListView' unnamed='1' visible='1' window=':Options_Core::Internal::SettingsDialog'}
-:Qt Creator.Clear_QToolButton {text='Clear' type='QToolButton' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
-:Qt Creator.Issues_QListView {type='QListView' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow' windowTitle='Issues'}
-:Qt Creator.QtCreator.MenuBar_QMenuBar {name='QtCreator.MenuBar' type='QMenuBar' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
-:Qt Creator_Core::Internal::MainWindow {type='Core::Internal::MainWindow' unnamed='1' visible='1'}
-:Qt Creator_Find::Internal::SearchResultTreeView {type='Find::Internal::SearchResultTreeView' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
-:Qt Creator_QmlJSEditor::QmlJSTextEditorWidget {type='QmlJSEditor::QmlJSTextEditorWidget' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
-:Qt Creator_Utils::NavigationTreeView {type='Utils::NavigationTreeView' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
-:addToVersionControlComboBox_QComboBox {buddy=':New Qt Quick Application.Add to version control:_QLabel' name='addToVersionControlComboBox' type='QComboBox' visible='1'}
-:m_popupFrame_QListView {container=':m_popupFrame_TextEditor::GenericProposalWidget' type='QListView' unnamed='1' visible='1'}
-:m_popupFrame_TextEditor::GenericProposalWidget {name='m_popupFrame' type='TextEditor::GenericProposalWidget' visible='1'}
-:qt_tabwidget_stackedwidget.CppTools__Internal__CompletionSettingsPage_QWidget {container=':Options.qt_tabwidget_stackedwidget_QStackedWidget' name='CppTools__Internal__CompletionSettingsPage' type='QWidget' visible='1'}
diff --git a/tests/system/suite_QMLS/suite.conf b/tests/system/suite_QMLS/suite.conf
index 321ab6db4b..c937c87736 100644
--- a/tests/system/suite_QMLS/suite.conf
+++ b/tests/system/suite_QMLS/suite.conf
@@ -1,10 +1,12 @@
AUT=qtcreator
CLASS=
CLASSPATH=
+CWD=
ENVVARS=envvars
HOOK_SUB_PROCESSES=false
IMPLICITAUTSTART=0
LANGUAGE=Python
+OBJECTMAP=../objects.map
TEST_CASES=tst_QMLS01 tst_QMLS02 tst_QMLS03 tst_QMLS04 tst_QMLS05 tst_QMLS06 tst_QMLS07 tst_QMLS08
VERSION=2
WRAPPERS=Qt
diff --git a/tests/system/suite_QMLS/tst_QMLS01/test.py b/tests/system/suite_QMLS/tst_QMLS01/test.py
index b76dd10106..f7d26b9a6e 100644
--- a/tests/system/suite_QMLS/tst_QMLS01/test.py
+++ b/tests/system/suite_QMLS/tst_QMLS01/test.py
@@ -14,7 +14,7 @@ def __beginTestSuggestions__(editorArea, lineText, textToType):
# verify whether suggestions makes sense for typed textToType
def verifySuggestions(textToType):
- popup = findObject(":m_popupFrame_QListView")
+ popup = findObject(":popupFrame_Proposal_QListView")
model = popup.model()
for row in range(model.rowCount()):
index = model.index(row, 0)
@@ -35,12 +35,12 @@ def testSuggestionsAuto(lineText, textToType, expectedText, keyToUseSuggestion):
if not __beginTestSuggestions__(editorArea, lineText, textToType):
return False
# check if suggestions are shown
- test.verify(checkIfObjectExists(":m_popupFrame_QListView"),
+ test.verify(checkIfObjectExists(":popupFrame_Proposal_QListView"),
"Verifying if suggestions in automatic mode are shown.")
# verify proposed suggestions
verifySuggestions(textToType)
# test if suggestion can be selected with keyToUseSuggestion
- type(findObject(":m_popupFrame_QListView"), keyToUseSuggestion)
+ type(findObject(":popupFrame_Proposal_QListView"), keyToUseSuggestion)
# get text which was written by usage of suggestion
typedText = str(lineUnderCursor(editorArea)).strip()
# verify if expected text is written
@@ -56,7 +56,7 @@ def testSuggestionsManual(lineText, textToType, expectedText):
if not __beginTestSuggestions__(editorArea, lineText, textToType):
return False
# wait if automatic popup displayed - if yes then fail, because we are in manual mode
- test.verify(checkIfObjectExists(":m_popupFrame_QListView", False),
+ test.verify(checkIfObjectExists(":popupFrame_Proposal_QListView", False),
"Verifying if suggestions in manual mode are properly not automatically shown")
# test if suggestion can be invoked manually
if platform.system() == "Darwin":
@@ -64,12 +64,12 @@ def testSuggestionsManual(lineText, textToType, expectedText):
else:
type(editorArea, "<Ctrl+Space>")
# check if suggestions are shown
- test.verify(checkIfObjectExists(":m_popupFrame_QListView"),
+ test.verify(checkIfObjectExists(":popupFrame_Proposal_QListView"),
"Verifying if suggestions in manual mode are shown manually")
# verify proposed suggestions
verifySuggestions(textToType)
# test if suggestion can be used
- type(findObject(":m_popupFrame_QListView"), "<Return>")
+ type(findObject(":popupFrame_Proposal_QListView"), "<Return>")
# get text which was written by usage of suggestion
typedText = str(lineUnderCursor(editorArea)).strip()
# verify if expected text is written
@@ -106,4 +106,3 @@ def main():
testSuggestionsManual("Text {", "col", "color:")
# exit qt creator
saveAndExit()
-
diff --git a/tests/system/suite_QMLS/tst_QMLS03/test.py b/tests/system/suite_QMLS/tst_QMLS03/test.py
index bbd4facd23..9733291871 100644
--- a/tests/system/suite_QMLS/tst_QMLS03/test.py
+++ b/tests/system/suite_QMLS/tst_QMLS03/test.py
@@ -71,7 +71,7 @@ def main():
resultsView = waitForObject(":Qt Creator_Find::Internal::SearchResultTreeView")
test.verify(checkUsages(resultsView, expectedResults), "Verifying if usages were properly found using context menu.")
# clear previous results & prepare for next search
- clickButton(waitForObject(":Qt Creator.Clear_QToolButton"))
+ clickButton(waitForObject(":*Qt Creator.Clear_QToolButton"))
mouseClick(editorArea, 5, 5, 0, Qt.LeftButton)
# 2. check usages using menu
# place cursor to component
@@ -89,7 +89,7 @@ def main():
resultsView = waitForObject(":Qt Creator_Find::Internal::SearchResultTreeView")
test.verify(checkUsages(resultsView, expectedResults), "Verifying if usages were properly found using main menu.")
# clear previous results & prepare for next search
- clickButton(waitForObject(":Qt Creator.Clear_QToolButton"))
+ clickButton(waitForObject(":*Qt Creator.Clear_QToolButton"))
mouseClick(editorArea, 5, 5, 0, Qt.LeftButton)
# 3. check usages using keyboard shortcut
# place cursor to component