Merge lp:~aacid/unity-2d/unity-2d_test_launcher_autohide_bug into lp:unity-2d

Proposed by Albert Astals Cid
Status: Merged
Approved by: Michał Sawicz
Approved revision: 928
Merged at revision: 928
Proposed branch: lp:~aacid/unity-2d/unity-2d_test_launcher_autohide_bug
Merge into: lp:unity-2d
Diff against target: 65 lines (+39/-0)
3 files modified
tests/launcher/autohide_show_tests.rb (+4/-0)
tests/launcher/autohide_show_tests_common.rb (+31/-0)
tests/launcher/autohide_show_tests_rtl.rb (+4/-0)
To merge this branch: bzr merge lp:~aacid/unity-2d/unity-2d_test_launcher_autohide_bug
Reviewer Review Type Date Requested Status
Michał Sawicz Pending
Review via email: mp+93844@code.launchpad.net

Description of the change

Test for bug regarding Auto Hide and moving the mouse to the launcher after it has been shown because of focus

To post a comment you must log in.
928. By Albert Astals Cid

There's no xid in here

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'tests/launcher/autohide_show_tests.rb'
2--- tests/launcher/autohide_show_tests.rb 2012-02-13 14:42:06 +0000
3+++ tests/launcher/autohide_show_tests.rb 2012-02-20 16:47:21 +0000
4@@ -184,5 +184,9 @@
5 test "Launcher does not hide on Esc after Super with overlapping window and mouse on BFB" do
6 test_launcher_does_not_hide_on_esc_after_Super_with_overlapping_window_mouse_on_bfb()
7 end
8+
9+ test "Auto Hide: Launcher does not hide on Esc after Alt+F1 and mouse on BFB" do
10+ test_auto_hide_launcher_does_not_hide_on_esc_after_alt_f1_mouse_on_bfb()
11+ end
12
13 end
14
15=== modified file 'tests/launcher/autohide_show_tests_common.rb'
16--- tests/launcher/autohide_show_tests_common.rb 2012-02-07 11:18:21 +0000
17+++ tests/launcher/autohide_show_tests_common.rb 2012-02-20 16:47:21 +0000
18@@ -555,3 +555,34 @@
19 }
20 xid.close!
21 end
22+
23+# Test case objectives:
24+# * Auto Hide: Launcher does not hide on Esc after Alt+F1 with mouse on the bfb
25+# Pre-conditions
26+# * Desktop with no running applications
27+# Test steps
28+# * Set hide-mode to 1
29+# * Move mouse outside the launcher
30+# * Verify Launcher hiding
31+# * Press Alt+F1
32+# * Verify Launcher showing
33+# * Move mouse to the bfb
34+# * Press Esc
35+# * Verify Launcher does not hide
36+# Post-conditions
37+# * None
38+# References
39+# * None
40+def test_auto_hide_launcher_does_not_hide_on_esc_after_alt_f1_mouse_on_bfb
41+ $SUT.execute_shell_command 'gsettings set com.canonical.Unity2d.Launcher hide-mode 1'
42+ XDo::Mouse.move(300, 300, 0, true)
43+ verify_launcher_hidden(TIMEOUT, 'Launcher visible, should be hidden')
44+ XDo::Keyboard.alt_F1 #Must use uppercase F to indicate function keys
45+ verify_launcher_visible(TIMEOUT, 'Launcher hidden, should be visible')
46+ bfb = @app.LauncherList( :name => 'main' ).LauncherList( :isBfb => true );
47+ bfb.move_mouse()
48+ XDo::Keyboard.escape
49+ verify_not(0, 'Launcher hiding after on Esc after Alt+F1 with mouse over bfb') {
50+ verify_launcher_hidden(2)
51+ }
52+end
53
54=== modified file 'tests/launcher/autohide_show_tests_rtl.rb'
55--- tests/launcher/autohide_show_tests_rtl.rb 2012-02-13 14:42:06 +0000
56+++ tests/launcher/autohide_show_tests_rtl.rb 2012-02-20 16:47:21 +0000
57@@ -186,4 +186,8 @@
58 test_launcher_does_not_hide_on_esc_after_Super_with_overlapping_window_mouse_on_bfb()
59 end
60
61+ test "Auto Hide: Launcher does not hide on Esc after Alt+F1 and mouse on BFB" do
62+ test_auto_hide_launcher_does_not_hide_on_esc_after_alt_f1_mouse_on_bfb()
63+ end
64+
65 end

Subscribers

People subscribed via source and target branches