Merge lp:~om26er/qtcreator-plugin-ubuntu/wait_for_button_to_be_visible into lp:~bzoltan/qtcreator-plugin-ubuntu/new_tests

Proposed by Omer Akram
Status: Merged
Merged at revision: 219
Proposed branch: lp:~om26er/qtcreator-plugin-ubuntu/wait_for_button_to_be_visible
Merge into: lp:~bzoltan/qtcreator-plugin-ubuntu/new_tests
Diff against target: 26 lines (+8/-6)
1 file modified
tests/autopilot/qtcreator_plugin_ubuntu/tests/test_qtcreator_plugin_functionality.py (+8/-6)
To merge this branch: bzr merge lp:~om26er/qtcreator-plugin-ubuntu/wait_for_button_to_be_visible
Reviewer Review Type Date Requested Status
Zoltan Balogh Pending
Review via email: mp+227079@code.launchpad.net

Description of the change

wait for the new button to be visible before clicking.

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'tests/autopilot/qtcreator_plugin_ubuntu/tests/test_qtcreator_plugin_functionality.py'
2--- tests/autopilot/qtcreator_plugin_ubuntu/tests/test_qtcreator_plugin_functionality.py 2014-07-16 17:20:21 +0000
3+++ tests/autopilot/qtcreator_plugin_ubuntu/tests/test_qtcreator_plugin_functionality.py 2014-07-16 18:04:51 +0000
4@@ -24,15 +24,17 @@
5 """ Change to the Devices mode and click on the add new emulator button """
6 kbd = Keyboard.create("X11")
7 kbd.press_and_release('Ctrl+9')
8- devices_quickview = self.ide.wait_select_single('QQuickView', source = 'file:///usr/share/qtcreator/ubuntu/devicespage/main.qml')
9- add_emulator_button = devices_quickview.wait_select_single('Button', text = 'Add Emulator')
10- self.assertIsNot(add_emulator_button, None)
11- if (add_emulator_button.enabled): print('Enabled')
12- self.pointing_device.move_to_object(add_emulator_button)
13+ devices_quickview = self.ide.wait_select_single(
14+ 'QQuickView',
15+ source='file:///usr/share/qtcreator/ubuntu/devicespage/main.qml')
16+ add_emulator_button = devices_quickview.select_single(
17+ 'Button', text='Add Emulator')
18+ add_emulator_button.visible.wait_for(True)
19 self.pointing_device.click_object(add_emulator_button)
20
21 sleep(2)
22-# config_emulator_dialog = devices_quickview.wait_select_single('Dialog', title = 'Create emulator')
23+ config_emulator_dialog = devices_quickview.wait_select_single(
24+ 'Dialog', title='Create emulator')
25 # QQuickLoader
26 #page10 -> SplitView -> QQuickItem -> SplitView -> QQuickItem -> ToolBar-> QQuickItem -> QQuickRow -> Button text='Add Emulator'
27

Subscribers

People subscribed via source and target branches

to all changes: