/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/tests/test_transform.py

  • Committer: Breezy landing bot
  • Author(s): Jelmer Vernooij
  • Date: 2018-11-22 03:51:03 UTC
  • mfrom: (7192.5.2 remove-more-file-ids)
  • Revision ID: breezy.the.bot@gmail.com-20181122035103-1c5jnbdx2t5yujqb
Stop actually accepting optional file_id in many Tree methods.

Merged from https://code.launchpad.net/~jelmer/brz/remove-more-file-ids/+merge/358950

Show diffs side-by-side

added added

removed removed

Lines of Context:
2094
2094
        calls = []
2095
2095
        real_source_get_file = source.get_file
2096
2096
 
2097
 
        def get_file(path, file_id=None):
2098
 
            calls.append(file_id)
2099
 
            return real_source_get_file(path, file_id)
 
2097
        def get_file(path):
 
2098
            calls.append(path)
 
2099
            return real_source_get_file(path)
2100
2100
        source.get_file = get_file
2101
2101
        target = self.make_branch_and_tree('target')
2102
2102
        revision_tree = source.basis_tree()
2103
2103
        revision_tree.lock_read()
2104
2104
        self.addCleanup(revision_tree.unlock)
2105
2105
        build_tree(revision_tree, target, source)
2106
 
        self.assertEqual([b'file1-id'], calls)
 
2106
        self.assertEqual(['file1'], calls)
2107
2107
        target.lock_read()
2108
2108
        self.addCleanup(target.unlock)
2109
2109
        self.assertEqual([], list(target.iter_changes(revision_tree)))
2147
2147
        calls = []
2148
2148
        real_source_get_file = source.get_file
2149
2149
 
2150
 
        def get_file(path, file_id=None):
2151
 
            calls.append(file_id)
2152
 
            return real_source_get_file(path, file_id)
 
2150
        def get_file(path):
 
2151
            calls.append(path)
 
2152
            return real_source_get_file(path)
2153
2153
        source.get_file = get_file
2154
2154
        target = self.make_branch_and_tree('target')
2155
2155
        revision_tree = source.basis_tree()