~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/branch.py

(jelmer) Misc fixes for running the regular bzr tests against foreign
 branches. (Jelmer Vernooij)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1372
1372
        # specific check.
1373
1373
        return result
1374
1374
 
1375
 
    def _get_checkout_format(self):
 
1375
    def _get_checkout_format(self, lightweight=False):
1376
1376
        """Return the most suitable metadir for a checkout of this branch.
1377
1377
        Weaves are used if this branch's repository uses weaves.
1378
1378
        """
1424
1424
        """
1425
1425
        t = transport.get_transport(to_location)
1426
1426
        t.ensure_base()
 
1427
        format = self._get_checkout_format(lightweight=lightweight)
1427
1428
        if lightweight:
1428
 
            format = self._get_checkout_format()
1429
1429
            checkout = format.initialize_on_transport(t)
1430
1430
            from_branch = BranchReferenceFormat().initialize(checkout, 
1431
1431
                target_branch=self)
1432
1432
        else:
1433
 
            format = self._get_checkout_format()
1434
1433
            checkout_branch = bzrdir.BzrDir.create_branch_convenience(
1435
1434
                to_location, force_new_tree=False, format=format)
1436
1435
            checkout = checkout_branch.bzrdir