~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/branch_implementations/test_branch.py

  • Committer: Robert Collins
  • Date: 2006-07-04 17:23:00 UTC
  • mto: This revision was merged to the branch mainline in revision 1840.
  • Revision ID: robertc@robertcollins.net-20060704172300-c4af39f04babcab8
(robertc) Teach repository.get_revision_graph, and revision.common_ancestor, about NULL_REVISION.

Show diffs side-by-side

added added

removed removed

Lines of Context:
29
29
                           NotBranchError,
30
30
                           )
31
31
from bzrlib.osutils import getcwd
 
32
import bzrlib.revision
32
33
from bzrlib.tests import TestCase, TestCaseWithTransport, TestSkipped
33
34
from bzrlib.tests.bzrdir_implementations.test_bzrdir import TestCaseWithBzrDir
34
35
from bzrlib.trace import mutter
358
359
        tree.branch.generate_revision_history(rev1)
359
360
        self.assertEqual(orig_history, tree.branch.revision_history())
360
361
 
 
362
    def test_generate_revision_history_NULL_REVISION(self):
 
363
        tree = self.make_branch_and_tree('.')
 
364
        rev1 = tree.commit('foo')
 
365
        tree.branch.generate_revision_history(bzrlib.revision.NULL_REVISION)
 
366
        self.assertEqual([], tree.branch.revision_history())
 
367
 
361
368
 
362
369
class ChrootedTests(TestCaseWithBranch):
363
370
    """A support class that provides readonly urls outside the local namespace.