~ahasenack/landscape-client/landscape-client-11.02

« back to all changes in this revision

Viewing changes to landscape/tests/helpers.py

  • Committer: Bazaar Package Importer
  • Author(s): Free Ekanayaka
  • Date: 2010-07-28 08:14:02 UTC
  • mfrom: (1.1.18 upstream)
  • Revision ID: james.westby@ubuntu.com-20100728081402-2ygupluqwc2bbe8j
Tags: 1.5.4-0ubuntu0.10.10.0
* New upstream version (LP: #610744):

  - The Eucalyptus management plugin reports the output of the
    'euca-describe-availability-zones verbose' command, which includes
    information about the available instance types and the maximum
    number of each instance type that the cloud can support (LP: #599338)

  - Check if the package directory exists before trying to check the
    package changer lock in the dbus-proxy. This fixes a bug when upgrading
    a dbus-landscape which never registered (LP: #603514).

  - Allow an LDS server to bootstrap new cloud instances with its own CA,
    which is picked up by the client, written to a file on the instance, and
    used in subsequent exchanges with the server (LP: #605079).

  - Skip loopback interface when reporting device info (LP: #608314)

  - Disable landscape-sysinfo when load is more than 1 (LP: #608278)

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
from landscape.tests.mocker import MockerTestCase
16
16
from landscape.watchdog import bootstrap_list
17
17
 
18
 
from landscape.lib import bpickle_dbus
19
18
from landscape.lib.persist import Persist
20
19
 
21
20
from landscape.reactor import FakeReactor
169
168
        run_isolated(LandscapeTest, self, result)
170
169
 
171
170
 
172
 
class DBusHelper(object):
173
 
    """Create a temporary D-Bus."""
174
 
 
175
 
    def set_up(self, test_case):
176
 
        if not getattr(test_case, "I_KNOW", False):
177
 
            test_case.assertTrue(isinstance(test_case, LandscapeIsolatedTest),
178
 
                                 "DBusHelper must only be used on "
179
 
                                 "LandscapeIsolatedTests")
180
 
        bpickle_dbus.install()
181
 
        test_case.bus = dbus.SessionBus()
182
 
 
183
 
    def tear_down(self, test_case):
184
 
        bpickle_dbus.uninstall()
185
 
 
186
 
 
187
171
class ErrorHandler(Handler):
188
172
 
189
173
    def __init__(self, *args, **kwargs):