Merge lp:~sil2100/unity/autopilot_hud_more_fixes into lp:unity
Status: | Merged |
---|---|
Approved by: | Łukasz Zemczak |
Approved revision: | no longer in the source branch. |
Merged at revision: | 3337 |
Proposed branch: | lp:~sil2100/unity/autopilot_hud_more_fixes |
Merge into: | lp:unity |
Diff against target: |
125 lines (+35/-17) 3 files modified
tests/autopilot/unity/emulators/hud.py (+9/-0) tests/autopilot/unity/tests/test_hud.py (+20/-16) tests/autopilot/unity/tests/test_search.py (+6/-1) |
To merge this branch: | bzr merge lp:~sil2100/unity/autopilot_hud_more_fixes |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
PS Jenkins bot (community) | continuous-integration | Approve | |
Francis Ginther | Approve | ||
Andrea Azzarone (community) | Approve | ||
Review via email: mp+164880@code.launchpad.net |
Commit message
Modify all the hud_query_check lambdas to be more smart and error-checking. Same for the selected_hud_button method in the HUD emulator.
Also, get rid of the troublesome test_gedit_undo and change it into test_gedit_save, which is easier to test and anyway tests what we want.
Besides that we also now try to handle the StateNotFoundError exception in the HUD emulator, another cause of some AP failures.
Description of the change
- Problem:
Some HUD tests are still failing, which is blocking the QA stack. The problem for that are differences on how HUD is returning the results, it's not instant.
- Fix:
Most of the fixes are related to changing the hud_query_check() lambda to a more 'smart' function. We first check if there is any HUD button we can fetch the label for. We do that every time hud_query_check was used.
We're adding one additional check to selected_
Also, we get rid of the test_gedit_undo and change it into test_gedit_save. This test is used only to check if activating the menu entries in an application works and performs the actions (besides quitting). So, instead of performing a hard-to-test task like undo, I think 'save' is enough to test what we need.
- Tests:
N/A
LGTM.