~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_commit_merge.py

  • Committer: Martin Packman
  • Date: 2012-01-05 09:50:04 UTC
  • mfrom: (6424 +trunk)
  • mto: This revision was merged to the branch mainline in revision 6426.
  • Revision ID: martin.packman@canonical.com-20120105095004-mia9xb7y0efmto0v
Merge bzr.dev to resolve conflicts in bzrlib.builtins

Show diffs side-by-side

added added

removed removed

Lines of Context:
17
17
 
18
18
import os
19
19
 
20
 
from bzrlib import check, osutils
 
20
from bzrlib import (
 
21
    check,
 
22
    osutils,
 
23
    revision as _mod_revision,
 
24
    )
21
25
from bzrlib.errors import PointlessCommit
22
26
from bzrlib.tests import (
23
27
    TestCaseWithTransport,
55
59
        wty.commit('merge from x', rev_id='y@u-0-2', allow_pointless=False)
56
60
 
57
61
        self.assertEquals(by.revno(), 3)
58
 
        self.assertEquals(list(by.revision_history()),
59
 
                          [base_rev, 'y@u-0-1', 'y@u-0-2'])
 
62
        graph = wty.branch.repository.get_graph()
 
63
        self.addCleanup(wty.lock_read().unlock)
 
64
        self.assertEquals(list(
 
65
            graph.iter_lefthand_ancestry(by.last_revision(),
 
66
                [_mod_revision.NULL_REVISION])),
 
67
            ['y@u-0-2', 'y@u-0-1', base_rev])
60
68
        rev = by.repository.get_revision('y@u-0-2')
61
69
        self.assertEquals(rev.parent_ids,
62
70
                          ['y@u-0-1', 'x@u-0-1'])