~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/blackbox/test_conflicts.py

Merge fix for bug #646961 resolving conflicts

Show diffs side-by-side

added added

removed removed

Lines of Context:
19
19
    tests,
20
20
    workingtree,
21
21
    )
 
22
from bzrlib.tests import script
 
23
 
22
24
 
23
25
# FIXME: These don't really look at the output of the conflict commands, just
24
26
# the number of lines - there should be more examination.
126
128
        self.assertEqual('', err)
127
129
        out, err = self.run_bzr('conflicts')
128
130
        self.assertEqual(0, len(out.splitlines()))
 
131
 
 
132
class TestResolveSilentlyIgnore(script.TestCaseWithTransportAndScript):
 
133
 
 
134
    def test_bug_646961(self):
 
135
        self.run_script("""\
 
136
            $ bzr init base
 
137
            Created a standalone tree (format: 2a)
 
138
            $ cd base
 
139
            $ echo >file1
 
140
            $ bzr add
 
141
            adding file1
 
142
            $ bzr ci -m "stuff"
 
143
            2>Committing to: .../base/
 
144
            2>added file1
 
145
            2>Committed revision 1.
 
146
            $ cd ..
 
147
            $ bzr branch base branch
 
148
            2>Branched 1 revision(s).
 
149
            $ cd base
 
150
            $ echo "1" >> file1
 
151
            $ bzr ci -m "branch 1"
 
152
            2>Committing to: .../base/
 
153
            2>modified file1
 
154
            2>Committed revision 2.
 
155
            $ cd ../branch
 
156
            $ echo "2" >> file1
 
157
            $ bzr ci -m "branch 2"
 
158
            2>Committing to: .../branch/
 
159
            2>modified file1
 
160
            2>Committed revision 2.
 
161
            $ cd ../base
 
162
            $ bzr merge ../branch
 
163
            2> M  file1
 
164
            2>Text conflict in file1
 
165
            2>1 conflicts encountered.
 
166
            # The following succeeds silently without resolving the conflict
 
167
            $ bzr resolve file1 --take-other
 
168
            # The following wil fail when --take-other is implemented
 
169
            # for text conflicts
 
170
            $ bzr conflicts
 
171
            Text conflict in file1
 
172
            """)
 
173