~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/interversionedfile_implementations/test_join.py

  • Committer: Robert Collins
  • Date: 2008-03-20 00:43:25 UTC
  • mto: This revision was merged to the branch mainline in revision 3306.
  • Revision ID: robertc@robertcollins.net-20080320004325-ee5fzf6ax6cmjgfx
Refactor internals of knit implementations to implement get_parents_with_ghosts in terms of get_parent_map.

Show diffs side-by-side

added added

removed removed

Lines of Context:
248
248
        self.assertEqual(['base', 'notbase'], source.get_ancestry_with_ghosts(['notbase']))
249
249
        self.assertEqual(['base'], source.get_parents_with_ghosts('notbase'))
250
250
        self.assertEqual({'notbase':('base',)}, source.get_parent_map(['notbase']))
251
 
        self.assertEqual({'notbase':['base']}, source.get_graph_with_ghosts())
 
251
        self.assertEqual({'notbase':('base',)}, source.get_graph_with_ghosts())
252
252
        self.assertTrue(source.has_ghost('base'))
253
253
 
254
254
        # if we add something that is fills out what is a ghost, then 
265
265
        # we have _with_ghost apis to give us ghost information.
266
266
        self.assertEqual(['base', 'notbase'], target.get_ancestry_with_ghosts(['notbase']))
267
267
        self.assertEqual(['base'], target.get_parents_with_ghosts('notbase'))
268
 
        self.assertEqual({'base':[],
269
 
                          'notbase':['base'],
 
268
        self.assertEqual({'base':(),
 
269
                          'notbase':('base',),
270
270
                          },
271
271
                         target.get_graph_with_ghosts())
272
272
        self.assertFalse(target.has_ghost('base'))