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')
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')
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')