/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/branch_implementations/test_branch.py

  • Committer: Robert Collins
  • Date: 2008-04-04 00:43:07 UTC
  • mfrom: (3331 +trunk)
  • mto: This revision was merged to the branch mainline in revision 3333.
  • Revision ID: robertc@robertcollins.net-20080404004307-0whomfhm3yal2rvw
Resolve conflicts.

Show diffs side-by-side

added added

removed removed

Lines of Context:
57
57
 
58
58
    def test_create_tree_with_merge(self):
59
59
        tree = self.create_tree_with_merge()
60
 
        ancestry_graph = tree.branch.repository.get_revision_graph('rev-3')
61
 
        self.assertEqual({'rev-1':(),
 
60
        tree.lock_read()
 
61
        self.addCleanup(tree.unlock)
 
62
        graph = tree.branch.repository.get_graph()
 
63
        ancestry_graph = graph.get_parent_map(tree.branch.repository.all_revision_ids())
 
64
        self.assertEqual({'rev-1':('null:',),
62
65
                          'rev-2':('rev-1', ),
63
66
                          'rev-1.1.1':('rev-1', ),
64
67
                          'rev-3':('rev-2', 'rev-1.1.1', ),
214
217
        wt = self.make_branch_and_tree('.')
215
218
        wt.set_parent_ids(['non:existent@rev--ision--0--2'],
216
219
            allow_leftmost_as_ghost=True)
 
220
        self.assertEqual(['non:existent@rev--ision--0--2'],
 
221
            wt.get_parent_ids())
217
222
        rev_id = wt.commit('commit against a ghost first parent.')
218
223
        rev = wt.branch.repository.get_revision(rev_id)
219
224
        self.assertEqual(rev.parent_ids, ['non:existent@rev--ision--0--2'])