~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_merge_core.py

  • Committer: Robert Collins
  • Date: 2006-02-12 12:57:15 UTC
  • mto: (1534.1.22 integration)
  • mto: This revision was merged to the branch mainline in revision 1554.
  • Revision ID: robertc@robertcollins.net-20060212125715-75abf487b5ee1f5a
Add update command for use with checkouts.

Show diffs side-by-side

added added

removed removed

Lines of Context:
682
682
        a_wt = self.make_branch_and_tree('a')
683
683
        file('a/un','wb').write('UN')
684
684
        file('a/deux','wb').write('DEUX')
685
 
        a_wt.add('un')
686
 
        a_wt.add('deux')
687
 
        a_wt.commit('r0')
 
685
        a_wt.add('un', 'un')
 
686
        a_wt.add('deux', 'deux')
 
687
        a_wt.commit('r0', rev_id='r0')
688
688
        self.run_bzr('branch', 'a', 'b')
689
689
        b_wt = WorkingTree.open('b')
690
690
        b_wt.rename_one('un','tmp')
691
691
        b_wt.rename_one('deux','un')
692
692
        b_wt.rename_one('tmp','deux')
693
 
        b_wt.commit('r1')
694
 
        merge(['b', -1],['b', 1],this_dir='a')
695
 
        self.assert_(os.path.exists('a/un'))
696
 
        self.assert_(os.path.exists('a/deux'))
 
693
        b_wt.commit('r1', rev_id='r1')
 
694
        self.assertEqual(0, merge(['b', -1], ['b', 1], this_dir='a'))
 
695
        self.failUnlessExists('a/un')
 
696
        self.failUnless('a/deux')
697
697
        self.assertFalse(os.path.exists('a/tmp'))
698
698
        self.assertEqual(file('a/un').read(),'DEUX')
699
699
        self.assertEqual(file('a/deux').read(),'UN')