Merge lp:~thisfred/ubuntuone-control-panel/hail-discordia into lp:ubuntuone-control-panel

Proposed by Eric Casteleijn
Status: Merged
Approved by: Eric Casteleijn
Approved revision: 143
Merged at revision: 141
Proposed branch: lp:~thisfred/ubuntuone-control-panel/hail-discordia
Merge into: lp:ubuntuone-control-panel
Diff against target: 33 lines (+7/-0)
1 file modified
ubuntuone/controlpanel/gtk/tests/test_gui_basic.py (+7/-0)
To merge this branch: bzr merge lp:~thisfred/ubuntuone-control-panel/hail-discordia
Reviewer Review Type Date Requested Status
Manuel de la Peña (community) Approve
dobey (community) Approve
Review via email: mp+60189@code.launchpad.net

Commit message

Skip Unity test when Unity is not installed.

Description of the change

Skip Unity test when Unity is not installed.

To post a comment you must log in.
143. By Eric Casteleijn

skipIf

Revision history for this message
dobey (dobey) :
review: Approve
Revision history for this message
Manuel de la Peña (mandel) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'ubuntuone/controlpanel/gtk/tests/test_gui_basic.py'
2--- ubuntuone/controlpanel/gtk/tests/test_gui_basic.py 2011-04-13 18:44:45 +0000
3+++ ubuntuone/controlpanel/gtk/tests/test_gui_basic.py 2011-05-06 14:31:34 +0000
4@@ -20,15 +20,21 @@
5
6 from __future__ import division
7
8+
9 from ubuntuone.controlpanel.gtk import gui
10 from ubuntuone.controlpanel.gtk.tests import BaseTestCase, FakedSSOBackend
11 from ubuntuone.controlpanel.tests import TOKEN
12
13+from ubuntuone.devtools.testcase import skipIf
14
15 # Attribute 'yyy' defined outside __init__, access to a protected member
16 # pylint: disable=W0201, W0212
17
18
19+class FakeUnity(object):
20+ """Fake Unity module."""
21+
22+
23 class FakeLauncherEntryProps(object):
24 """A fake Unity.LauncherEntry.props"""
25
26@@ -138,6 +144,7 @@
27 """Max size is not bigger than 736x525 (LP: #645526, LP: #683164)."""
28 self.assertTrue(self.ui.get_size_request() <= (736, 525))
29
30+ @skipIf(not gui.USE_LIBUNITY, 'Must have Unity installed.')
31 def test_focus_handler(self):
32 """When the window receives focus, the handler is called."""
33 THE_FLEP.urgent = True

Subscribers

People subscribed via source and target branches