/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/repository_implementations/test_commit_builder.py

  • Committer: Aaron Bentley
  • Date: 2006-11-17 04:06:03 UTC
  • mfrom: (2139 +trunk)
  • mto: This revision was merged to the branch mainline in revision 2162.
  • Revision ID: aaron.bentley@utoronto.ca-20061117040603-pgebxndswvwk26tt
Merge from bzr.dev

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright (C) 2006 by Canonical Ltd
 
1
# Copyright (C) 2006 Canonical Ltd
2
2
#
3
3
# This program is free software; you can redistribute it and/or modify
4
4
# it under the terms of the GNU General Public License as published by
95
95
        # precisely test that - a repository that wants to can add it on deserialisation,
96
96
        # but thats all the current contract guarantees anyway.
97
97
        self.assertEqual(rev_id, tree.branch.repository.get_inventory(rev_id).revision_id)
 
98
 
 
99
    def test_revision_tree(self):
 
100
        tree = self.make_branch_and_tree(".")
 
101
        builder = tree.branch.get_commit_builder([])
 
102
        self.record_root(builder, tree)
 
103
        builder.finish_inventory()
 
104
        rev_id = builder.commit('foo bar')
 
105
        rev_tree = builder.revision_tree()
 
106
        # Just a couple simple tests to ensure that it actually follows
 
107
        # the RevisionTree api.
 
108
        self.assertEqual(rev_id, rev_tree.get_revision_id())
 
109
        self.assertEqual([], rev_tree.get_parent_ids())