~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_conflicts.py

  • Committer: Vincent Ladeuil
  • Date: 2011-09-29 15:50:58 UTC
  • mfrom: (6177 +trunk)
  • mto: This revision was merged to the branch mainline in revision 6178.
  • Revision ID: v.ladeuil+lp@free.fr-20110929155058-zgbecmx1huzktegm
Merge trunk and resolve conflicts

Show diffs side-by-side

added added

removed removed

Lines of Context:
677
677
             ('fileb_created',
678
678
              dict(actions='create_file_b', check='file_content_b',
679
679
                   path='file', file_id='file-b-id')),),
680
 
            # File created with different file-ids but deleted on one side
681
 
            (dict(_base_actions='create_file_a'),
682
 
             ('filea_replaced',
683
 
              dict(actions='replace_file_a_by_b', check='file_content_b',
684
 
                   path='file', file_id='file-b-id')),
685
 
             ('filea_modified',
686
 
              dict(actions='modify_file_a', check='file_new_content',
687
 
                   path='file', file_id='file-a-id')),),
688
680
            ])
689
681
 
690
682
    def do_nothing(self):
702
694
    def check_file_content_b(self):
703
695
        self.assertFileEqual('file b content\n', 'branch/file')
704
696
 
705
 
    def do_replace_file_a_by_b(self):
706
 
        return [('unversion', 'file-a-id'),
707
 
                ('add', ('file', 'file-b-id', 'file', 'file b content\n'))]
708
 
 
709
 
    def do_modify_file_a(self):
710
 
        return [('modify', ('file-a-id', 'new content\n'))]
711
 
 
712
 
    def check_file_new_content(self):
713
 
        self.assertFileEqual('new content\n', 'branch/file')
714
 
 
715
697
    def _get_resolve_path_arg(self, wt, action):
716
698
        return self._this['path']
717
699
 
1061
1043
        # This is nearly like TestResolveNonDirectoryParent but with branch and
1062
1044
        # trunk switched. As such it should certainly produce the same
1063
1045
        # conflict.
1064
 
        self.assertRaises(errors.MalformedTransform,
1065
 
                          self.run_script,"""
 
1046
        self.run_script("""
1066
1047
$ bzr init trunk
1067
1048
...
1068
1049
$ cd trunk