~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/selftest/testrevision.py

  • Committer: Martin Pool
  • Date: 2005-09-15 12:54:09 UTC
  • Revision ID: mbp@sourcefrog.net-20050915125408-c61e94cfbe83f4e7
- fix up testrevision to fetch revisions before marking them merged

Show diffs side-by-side

added added

removed removed

Lines of Context:
20
20
from bzrlib.selftest import TestCaseInTempDir
21
21
from bzrlib.branch import Branch
22
22
from bzrlib.commit import commit
23
 
from bzrlib.fetch import Fetcher
 
23
from bzrlib.fetch import fetch
24
24
 
25
25
def make_branches():
26
26
    os.mkdir("branch1")
37
37
    commit(br2, "Commit five", rev_id="b@u-0-4")
38
38
    revisions_2 = br2.revision_history()
39
39
    
40
 
    ## Fetch(from_branch=br2, to_branch=br1)
 
40
    fetch(from_branch=br2, to_branch=br1)
41
41
    br1.add_pending_merge(revisions_2[4])
42
42
    commit(br1, "Commit six", rev_id="a@u-0-3")
43
43
    commit(br1, "Commit seven", rev_id="a@u-0-4")
44
44
    commit(br2, "Commit eight", rev_id="b@u-0-5")
 
45
    
 
46
    fetch(from_branch=br2, to_branch=br1)
45
47
    br1.add_pending_merge(br2.revision_history()[5])
46
48
    commit(br1, "Commit nine", rev_id="a@u-0-5")
 
49
 
 
50
    fetch(from_branch=br1, to_branch=br2)
47
51
    br2.add_pending_merge(br1.revision_history()[4])
48
52
    commit(br2, "Commit ten", rev_id="b@u-0-6")
 
53
    
49
54
    return br1, br2
50
55
 
51
56