~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_bzrdir.py

  • Committer: Aaron Bentley
  • Date: 2007-01-11 03:46:53 UTC
  • mto: (2255.6.1 dirstate)
  • mto: This revision was merged to the branch mainline in revision 2322.
  • Revision ID: aaron.bentley@utoronto.ca-20070111034653-wa1n3uy49wbvom5m
Remove get_format_*, make FormatRegistry.register_metadir vary working tree

Show diffs side-by-side

added added

removed removed

Lines of Context:
70
70
            'BzrDirFormat6', 'Format registered lazily', deprecated=True)
71
71
        my_format_registry.register_metadir('knit', 'RepositoryFormatKnit1',
72
72
            'Format using knits')
 
73
        my_format_registry.register_metadir('experimental-knit3', 
 
74
                                            'RepositoryFormatKnit2',
 
75
                                            'Format using knits', 
 
76
                                            tree='WorkingTreeFormat4')
73
77
        my_format_registry.set_default('knit')
74
78
        my_format_registry.register_metadir('metaweave', 'RepositoryFormat7',
75
79
            'Transitional format in 0.8.  Slower than knit.', deprecated=True)
93
97
        my_bzrdir = my_format_registry.make_bzrdir('metaweave')
94
98
        self.assertIsInstance(my_bzrdir.repository_format, 
95
99
            repository.RepositoryFormat7)
 
100
        self.assertIsInstance(my_bzrdir.workingtree_format, 
 
101
            workingtree.WorkingTreeFormat3)
 
102
        my_bzrdir = my_format_registry.make_bzrdir('experimental-knit3')
 
103
        self.assertIsInstance(my_bzrdir.repository_format, 
 
104
            repository.RepositoryFormatKnit2)
 
105
        self.assertIsInstance(my_bzrdir.workingtree_format, 
 
106
            workingtree.WorkingTreeFormat4)
96
107
 
97
108
    def test_get_help(self):
98
109
        my_format_registry = self.make_format_registry()