/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/per_workingtree/test_commit.py

  • Committer: Robert Collins
  • Date: 2009-07-15 01:13:20 UTC
  • mto: This revision was merged to the branch mainline in revision 4544.
  • Revision ID: robertc@robertcollins.net-20090715011320-coi9b5psw5d3tr2r
Fix dirstate.set_state_from_inventory to have a more stable old_iterator, fixing rename problems in new trees. (Robert Collins, bug 395556)

Show diffs side-by-side

added added

removed removed

Lines of Context:
602
602
        revid = tree.commit('first post')
603
603
        committed_tree = tree.basis_tree()
604
604
        self.assertTrue(committed_tree.has_filename("newfile"))
605
 
 
606
 
    def test_commit_and_mv_dance_a(self):
607
 
        # should fail because of
608
 
        # <https://bugs.launchpad.net/bzr/+bug/395556> but apparently does
609
 
        # not, while the blackbox.test_commit equivalent does - maybe because
610
 
        # of different format combinations
611
 
        tree = self.make_branch_and_tree(".")
612
 
        self.build_tree(["a"])
613
 
        tree.add("a")
614
 
        tree.rename_one("a", "b")
615
 
        tree.commit("Actually no, b")
616
 
        tree.rename_one("b", "a")
617
 
        tree.commit("No, really, a")
618
 
 
619
 
    def test_commit_and_mv_dance_b(self):
620
 
        # should fail because of
621
 
        # <https://bugs.launchpad.net/bzr/+bug/395556> but apparently does
622
 
        # not, while the blackbox.test_commit equivalent does - maybe because
623
 
        # of different format combinations
624
 
        tree = self.make_branch_and_tree(".")
625
 
        self.build_tree(["b"])
626
 
        tree.add("b")
627
 
        tree.rename_one("b", "a")
628
 
        tree.commit("Actually no, a")
629
 
        tree.rename_one("a", "b")
630
 
        tree.commit("No, really, b")