~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_workingtree.py

  • Committer: John Arbash Meinel
  • Date: 2010-09-29 20:56:18 UTC
  • mto: This revision was merged to the branch mainline in revision 5452.
  • Revision ID: john@arbash-meinel.com-20100929205618-qlldxw4ykwt5511n
Move the new NEWS entry to the appropriate section.

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
# along with this program; if not, write to the Free Software
16
16
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
17
17
 
 
18
from cStringIO import StringIO
18
19
import os
19
20
 
20
21
from bzrlib import (
24
25
    transport,
25
26
    workingtree,
26
27
    )
 
28
from bzrlib.branch import Branch
 
29
from bzrlib.bzrdir import BzrDir
27
30
from bzrlib.lockdir import LockDir
28
31
from bzrlib.mutabletree import needs_tree_write_lock
29
32
from bzrlib.tests import TestCase, TestCaseWithTransport, TestSkipped
346
349
        self.build_tree_contents([('this/hello', 'Hello World')])
347
350
        this.commit('Add World')
348
351
        this.merge_from_branch(other.branch)
349
 
        self.assertEqual([conflicts.TextConflict('hello', 'hello_id')],
 
352
        self.assertEqual([conflicts.TextConflict('hello', None, 'hello_id')],
350
353
                         this.conflicts())
351
354
        this.auto_resolve()
352
 
        self.assertEqual([conflicts.TextConflict('hello', 'hello_id')],
 
355
        self.assertEqual([conflicts.TextConflict('hello', None, 'hello_id')],
353
356
                         this.conflicts())
354
357
        self.build_tree_contents([('this/hello', '<<<<<<<')])
355
358
        this.auto_resolve()
356
 
        self.assertEqual([conflicts.TextConflict('hello', 'hello_id')],
 
359
        self.assertEqual([conflicts.TextConflict('hello', None, 'hello_id')],
357
360
                         this.conflicts())
358
361
        self.build_tree_contents([('this/hello', '=======')])
359
362
        this.auto_resolve()
360
 
        self.assertEqual([conflicts.TextConflict('hello', 'hello_id')],
 
363
        self.assertEqual([conflicts.TextConflict('hello', None, 'hello_id')],
361
364
                         this.conflicts())
362
365
        self.build_tree_contents([('this/hello', '\n>>>>>>>')])
363
366
        remaining, resolved = this.auto_resolve()
364
 
        self.assertEqual([conflicts.TextConflict('hello', 'hello_id')],
 
367
        self.assertEqual([conflicts.TextConflict('hello', None, 'hello_id')],
365
368
                         this.conflicts())
366
369
        self.assertEqual([], resolved)
367
370
        self.build_tree_contents([('this/hello', 'hELLO wORLD')])
368
371
        remaining, resolved = this.auto_resolve()
369
372
        self.assertEqual([], this.conflicts())
370
 
        self.assertEqual([conflicts.TextConflict('hello', 'hello_id')],
 
373
        self.assertEqual([conflicts.TextConflict('hello', None, 'hello_id')],
371
374
                         resolved)
372
375
        self.failIfExists('this/hello.BASE')
373
376
 
375
378
        tree = self.make_branch_and_tree('tree')
376
379
        self.build_tree(['tree/hello/'])
377
380
        tree.add('hello', 'hello-id')
378
 
        file_conflict = conflicts.TextConflict('file', 'hello-id')
 
381
        file_conflict = conflicts.TextConflict('file', None, 'hello-id')
379
382
        tree.set_conflicts(conflicts.ConflictList([file_conflict]))
380
383
        tree.auto_resolve()
381
384