/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_registry.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2010-10-26 08:43:44 UTC
  • mfrom: (5514.2.1 trunk)
  • Revision ID: pqm@pqm.ubuntu.com-20101026084344-fip1ktaqjin2w720
(vila) Correctly set the Content-Type header when POSTing http
        requests (Vincent Ladeuil)

Show diffs side-by-side

added added

removed removed

Lines of Context:
20
20
import sys
21
21
 
22
22
from bzrlib import (
 
23
    branch,
23
24
    errors,
24
25
    osutils,
25
26
    registry,
286
287
            '\n\n'
287
288
        )
288
289
 
 
290
    def test_lazy_import_registry_foo(self):
 
291
        a_registry = registry.Registry()
 
292
        a_registry.register_lazy('foo', 'bzrlib.branch', 'Branch')
 
293
        a_registry.register_lazy('bar', 'bzrlib.branch', 'Branch.hooks')
 
294
        self.assertEqual(branch.Branch, a_registry.get('foo'))
 
295
        self.assertEqual(branch.Branch.hooks, a_registry.get('bar'))
 
296
 
289
297
    def test_lazy_import_registry(self):
290
298
        plugin_name = self.create_simple_plugin()
291
299
        a_registry = registry.Registry()