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

Merge from by-reference-trees

Show diffs side-by-side

added added

removed removed

Lines of Context:
655
655
        repository.add_inventory = raise_
656
656
        self.assertRaises(errors.NoSuchFile, tree.commit, message_callback=cb)
657
657
        self.assertFalse(cb.called)
 
658
 
 
659
    def test_nested_commit(self):
 
660
        """Commit in multiply-nested trees"""
 
661
        tree = self.make_branch_and_tree('.', format='experimental-knit3')
 
662
        subtree = self.make_branch_and_tree('subtree',
 
663
                                            format='experimental-knit3')
 
664
        subsubtree = self.make_branch_and_tree('subtree/subtree',
 
665
                                               format='experimental-knit3')
 
666
        subtree.add_reference(subsubtree)
 
667
        tree.add_reference(subtree)
 
668
        tree.commit('added reference', allow_pointless=False)
 
669
        self.assertIs(subsubtree.last_revision(), None,
 
670
                      'subsubtree was committed')
 
671
        self.assertIsNot(subtree.last_revision(), None,
 
672
                         'subtree was not committed')
 
673