~jelmer/brz/colocated-spec

« back to all changes in this revision

Viewing changes to breezy/tests/per_tree/test_test_trees.py

  • Committer: Jelmer Vernooij
  • Date: 2017-05-22 00:56:52 UTC
  • mfrom: (6621.2.26 py3_pokes)
  • Revision ID: jelmer@jelmer.uk-20170522005652-yjahcr9hwmjkno7n
Merge Python3 porting work ('py3 pokes')

Show diffs side-by-side

added added

removed removed

Lines of Context:
47
47
        self.assertEqual([], list(tree.unknowns()))
48
48
        # __iter__ has no strongly defined order
49
49
        self.assertEqual(
50
 
            set(['root-id', 'a-id', 'b-id', 'c-id']),
 
50
            {'root-id', 'a-id', 'b-id', 'c-id'},
51
51
            set(tree.all_file_ids()))
52
52
        self.assertEqual(
53
53
            [('', 'root-id'), ('a', 'a-id'), ('b', 'b-id'), ('b/c', 'c-id')],
65
65
        self.assertEqual([], list(tree.unknowns()))
66
66
        # __iter__ has no strongly defined order
67
67
        self.assertEqual(
68
 
            set(['root-id', 'a-id', 'b-id', 'c-id']),
 
68
            {'root-id', 'a-id', 'b-id', 'c-id'},
69
69
            set(tree.all_file_ids()))
70
70
        self.assertEqual(
71
71
            [('', 'root-id'), ('a', 'a-id'), ('b', 'b-id'), ('b/c', 'c-id')],
83
83
        self.assertEqual([], list(tree.unknowns()))
84
84
        # __iter__ has no strongly defined order
85
85
        self.assertEqual(
86
 
            set(['root-id', 'a-id', 'b-id', 'c-id']),
 
86
            {'root-id', 'a-id', 'b-id', 'c-id'},
87
87
            set(tree.all_file_ids()))
88
88
        self.assertEqual(
89
89
            [('', 'root-id'), ('a', 'a-id'), ('b', 'b-id'), ('b/c', 'c-id')],
101
101
        self.assertEqual([], list(tree.unknowns()))
102
102
        # __iter__ has no strongly defined order
103
103
        self.assertEqual(
104
 
            set(['root-id', 'a-id', 'b-id', 'c-id']),
 
104
            {'root-id', 'a-id', 'b-id', 'c-id'},
105
105
            set(tree.all_file_ids()))
106
106
        self.assertEqual(
107
107
            [('', 'root-id'), ('b', 'b-id'), ('d', 'a-id'), ('b/c', 'c-id')],
119
119
        self.assertEqual([], list(tree.unknowns()))
120
120
        # __iter__ has no strongly defined order
121
121
        self.assertEqual(
122
 
            set(['root-id', 'a-id', 'b-id', 'c-id']),
 
122
            {'root-id', 'a-id', 'b-id', 'c-id'},
123
123
            set(tree.all_file_ids()))
124
124
        self.assertEqual(
125
125
            [('', 'root-id'), ('b', 'b-id'), ('d', 'a-id'), ('b/c', 'c-id')],
137
137
        self.assertEqual([], list(tree.unknowns()))
138
138
        # __iter__ has no strongly defined order
139
139
        self.assertEqual(
140
 
            set(['root-id', 'a-id', 'b-id', 'c-id']),
 
140
            {'root-id', 'a-id', 'b-id', 'c-id'},
141
141
            set(tree.all_file_ids()))
142
142
        self.assertEqual(
143
143
            [('', 'root-id'), ('a', 'a-id'), ('b', 'b-id'), ('e', 'c-id')],
159
159
        # __iter__ has no strongly defined order
160
160
        tree_root = tree.path2id('')
161
161
        self.assertEqual(
162
 
            set([tree_root,
 
162
            {tree_root,
163
163
                '2file',
164
164
                '1top-dir',
165
165
                '1file-in-1topdir',
166
166
                '0dir-in-1topdir',
167
167
                 u'0utf\u1234file'.encode('utf8'),
168
168
                'symlink',
169
 
                 ]),
 
169
                 },
170
170
            set(tree.all_file_ids()))
171
171
        # note that the order of the paths and fileids is deliberately
172
172
        # mismatched to ensure that the result order is path based.
193
193
        # __iter__ has no strongly defined order
194
194
        tree_root = tree.path2id('')
195
195
        self.assertEqual(
196
 
            set([tree_root,
 
196
            {tree_root,
197
197
                '2file',
198
198
                '1top-dir',
199
199
                '1file-in-1topdir',
200
200
                '0dir-in-1topdir',
201
201
                 u'0utf\u1234file'.encode('utf8'),
202
 
                 ]),
 
202
                 },
203
203
            set(tree.all_file_ids()))
204
204
        # note that the order of the paths and fileids is deliberately
205
205
        # mismatched to ensure that the result order is path based.