~3v1n0/unity/launcher-controller-bamf-check

« back to all changes in this revision

Viewing changes to tests/autopilot/unity/tests/test_launcher.py

  • Committer: Tarmac
  • Author(s): Thomi Richards
  • Date: 2012-05-17 00:03:41 UTC
  • mfrom: (2350.3.9 autopilot-change)
  • Revision ID: tarmac-20120517000341-jsv4dqpx7v6fuse6
Remove autopilot from the unity source tree - large reorganization of the autopilot code.. Fixes: . Approved by Tim Penhey.

Show diffs side-by-side

added added

removed removed

Lines of Context:
7
7
# under the terms of the GNU General Public License version 3, as published
8
8
# by the Free Software Foundation.
9
9
 
 
10
from __future__ import absolute_import
 
11
 
 
12
from autopilot.emulators.bamf import Bamf
 
13
from autopilot.emulators.X11 import ScreenGeometry
 
14
from autopilot.matchers import Eventually
 
15
from autopilot.testcase import multiply_scenarios
10
16
import logging
11
17
import os
12
18
from subprocess import call
13
19
from testtools.matchers import Equals, NotEquals, LessThan, GreaterThan
14
20
from time import sleep
15
21
 
16
 
from autopilot.emulators.bamf import Bamf
17
 
from autopilot.emulators.unity.icons import BFBLauncherIcon
18
 
from autopilot.emulators.X11 import ScreenGeometry
19
 
from autopilot.matchers import Eventually
20
 
from autopilot.tests import AutopilotTestCase, multiply_scenarios
 
22
from unity.emulators.icons import BFBLauncherIcon
 
23
from unity.tests import UnityTestCase
21
24
 
22
25
logger = logging.getLogger(__name__)
23
26
 
38
41
    return multiply_scenarios(monitor_scenarios, launcher_mode_scenarios)
39
42
 
40
43
 
41
 
class LauncherTestCase(AutopilotTestCase):
 
44
class LauncherTestCase(UnityTestCase):
42
45
    """A base class for all launcher tests that uses scenarios to run on
43
46
    each launcher (for multi-monitor setups).
44
47
    """
680
683
            self.assertOnlyOneLauncherIcon(application_id=icon.application_id)
681
684
 
682
685
 
683
 
class LauncherCaptureTests(AutopilotTestCase):
 
686
class LauncherCaptureTests(UnityTestCase):
684
687
    """Test the launchers ability to capture/not capture the mouse."""
685
688
 
686
689
    screen_geo = ScreenGeometry()
781
784
        self.assertThat(x_fin, LessThan(x + width * 1.5))
782
785
 
783
786
 
784
 
class LauncherTooltipTests(AutopilotTestCase):
 
787
class LauncherTooltipTests(UnityTestCase):
785
788
    """Test the launcher tooltips"""
786
789
 
787
790
    def setUp(self):