~jelmer/brz/reforma

« back to all changes in this revision

Viewing changes to breezy/tests/per_workingtree/test_transform.py

  • Committer: The Breezy Bot
  • Author(s): Jelmer Vernooij
  • Date: 2023-04-17 17:26:53 UTC
  • mfrom: (7730.1.1 osutils)
  • Revision ID: the_breezy_bot-20230417172653-e7ipapvc2342wong
Move more osutils functionality to rust

by jelmer review by jelmer

Show diffs side-by-side

added added

removed removed

Lines of Context:
830
830
                            'b\N{Euro Sign}hind_curtain')
831
831
 
832
832
    def test_unsupported_symlink_no_conflict(self):
833
 
        def tt_helper():
834
 
            wt = self.make_branch_and_tree('.')
835
 
            tt = wt.transform()
836
 
            self.addCleanup(tt.finalize)
837
 
            tt.new_symlink('foo', tt.root, 'bar')
838
 
            result = tt.find_raw_conflicts()
839
 
            self.assertEqual([], result)
840
 
        os_symlink = getattr(os, 'symlink', None)
841
 
        os.symlink = None
842
 
        try:
843
 
            tt_helper()
844
 
        finally:
845
 
            if os_symlink:
846
 
                os.symlink = os_symlink
 
833
        self.overrideAttr(os, "symlink", None)
 
834
        self.overrideAttr(osutils, "supports_symlinks", lambda x: False)
 
835
        wt = self.make_branch_and_tree('.')
 
836
        tt = wt.transform()
 
837
        self.addCleanup(tt.finalize)
 
838
        tt.new_symlink('foo', tt.root, 'bar')
 
839
        result = tt.find_raw_conflicts()
 
840
        self.assertEqual([], result)
847
841
 
848
842
    def get_conflicted(self):
849
843
        create, root = self.transform()