~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/blackbox/test_merge.py

  • Committer: John Arbash Meinel
  • Date: 2007-12-05 18:47:51 UTC
  • mfrom: (3079 +trunk)
  • mto: This revision was merged to the branch mainline in revision 3080.
  • Revision ID: john@arbash-meinel.com-20071205184751-58fi7xoj8ddox6ch
[merge] bzr.dev 3079

Show diffs side-by-side

added added

removed removed

Lines of Context:
392
392
        # pick 1 revision with option --changes
393
393
        self.run_bzr('merge -d target -c revid:rev_d source')
394
394
        self.assertDirectoryContent('target', ['.bzr', 'a', 'd'])
 
395
 
 
396
    def test_merge_criss_cross(self):
 
397
        tree_a = self.make_branch_and_tree('a')
 
398
        tree_a.commit('', rev_id='rev1')
 
399
        tree_b = tree_a.bzrdir.sprout('b').open_workingtree()
 
400
        tree_a.commit('', rev_id='rev2a')
 
401
        tree_b.commit('', rev_id='rev2b')
 
402
        tree_a.merge_from_branch(tree_b.branch)
 
403
        tree_b.merge_from_branch(tree_a.branch)
 
404
        tree_a.commit('', rev_id='rev3a')
 
405
        tree_b.commit('', rev_id='rev3b')
 
406
        graph = tree_a.branch.repository.get_graph(tree_b.branch.repository)
 
407
        out, err = self.run_bzr(['merge', '-d', 'a', 'b'])
 
408
        self.assertContainsRe(err, 'Warning: criss-cross merge encountered.')