~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_commit_merge.py

  • Committer: Vincent Ladeuil
  • Date: 2007-03-13 17:00:20 UTC
  • mfrom: (2352 +trunk)
  • mto: (2323.7.1 redirection)
  • mto: This revision was merged to the branch mainline in revision 2390.
  • Revision ID: v.ladeuil+lp@free.fr-20070313170020-d0oimozr96pwconh
Merge bzr.dev

Show diffs side-by-side

added added

removed removed

Lines of Context:
22
22
from bzrlib.branch import Branch
23
23
from bzrlib.errors import PointlessCommit, BzrError
24
24
from bzrlib.tests.test_revision import make_branches
 
25
from bzrlib import osutils
25
26
 
26
27
 
27
28
class TestCommitMerge(TestCaseWithTransport):
96
97
        by.check()
97
98
        bx.repository.check([bx.last_revision()])
98
99
        by.repository.check([by.last_revision()])
 
100
 
 
101
    def test_merge_with_symlink(self):
 
102
        if not osutils.has_symlinks():
 
103
            raise TestSkipped('Symlinks are not supported on this platform')
 
104
        tree_a = self.make_branch_and_tree('tree_a')
 
105
        os.symlink('target', osutils.pathjoin('tree_a', 'link'))
 
106
        tree_a.add('link')
 
107
        tree_a.commit('added link')
 
108
        tree_b = tree_a.bzrdir.sprout('tree_b').open_workingtree()
 
109
        self.build_tree(['tree_a/file'])
 
110
        tree_a.add('file')
 
111
        tree_a.commit('added file')
 
112
        self.build_tree(['tree_b/another_file'])
 
113
        tree_b.add('another_file')
 
114
        tree_b.commit('add another file')
 
115
        tree_b.merge_from_branch(tree_a.branch)
 
116
        tree_b.commit('merge')