/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/per_tree/test_ids.py

  • Committer: Jelmer Vernooij
  • Date: 2018-11-16 23:15:15 UTC
  • mfrom: (7180 work)
  • mto: This revision was merged to the branch mainline in revision 7183.
  • Revision ID: jelmer@jelmer.uk-20181116231515-zqd2yn6kj8lfydyp
Merge trunk.

Show diffs side-by-side

added added

removed removed

Lines of Context:
29
29
        if not work_a.supports_setting_file_ids():
30
30
            self.skipTest("working tree does not support setting file ids")
31
31
        self.build_tree(['wta/bla', 'wta/dir/', 'wta/dir/file'])
32
 
        work_a.add(['bla', 'dir', 'dir/file'], [b'bla-id', b'dir-id', b'file-id'])
 
32
        work_a.add(['bla', 'dir', 'dir/file'],
 
33
                   [b'bla-id', b'dir-id', b'file-id'])
33
34
        work_a.commit('add files')
34
35
        self.tree_a = self.workingtree_to_test_tree(work_a)
35
36
 
54
55
        self.assertEqual('dir/file', self.tree_a.id2path(b'file-id'))
55
56
        self.assertRaises(errors.NoSuchId, self.tree_a.id2path, b'nonexistant')
56
57
 
 
58
 
57
59
class Path2IdsTests(TestCaseWithTree):
58
60
 
59
61
    def test_paths2ids_recursive(self):
82
84
        tree.lock_read()
83
85
        self.addCleanup(tree.unlock)
84
86
        self.assertEqual(set([]), tree.paths2ids(['file'],
85
 
                         require_versioned=False))
 
87
                                                 require_versioned=False))