/breezy-hg/trunk

To get this branch, use:
bzr branch https://code.breezy-vcs.org/breezy-hg/trunk

« back to all changes in this revision

Viewing changes to tree.py

  • Committer: Jelmer Vernooij
  • Date: 2018-09-29 06:58:51 UTC
  • Revision ID: jelmer@jelmer.uk-20180929065851-dom63z9baz6guvru
Fix brz-hg specific tests.

Show diffs side-by-side

added added

removed removed

Lines of Context:
159
159
        ie.revision = self.get_file_revision(file_id, path)
160
160
        return ie
161
161
 
162
 
    def iter_entries_by_dir(self, specific_file_ids=None, yield_parents=False):
 
162
    def iter_entries_by_dir(self, specific_files=None, yield_parents=False):
163
163
        # FIXME: Support specific_file_ids and yield_parents
164
 
        if specific_file_ids is not None:
 
164
        if specific_files is not None:
165
165
            raise NotImplementedError(self.iter_entries_by_dir)
166
166
        directories = set()
167
167
        for p in self._manifest:
311
311
            return True
312
312
        # FIXME: What about directories?
313
313
        return False
 
314
 
 
315
    def find_related_paths_across_trees(self, paths, trees=[],
 
316
            require_versioned=True):
 
317
        if paths is None:
 
318
            return None
 
319
        if require_versioned:
 
320
            trees = [self] + (trees if trees is not None else [])
 
321
            unversioned = set()
 
322
            for p in paths:
 
323
                for t in trees:
 
324
                    if t.is_versioned(p):
 
325
                        break
 
326
                else:
 
327
                    unversioned.add(p)
 
328
            if unversioned:
 
329
                raise errors.PathsNotVersionedError(unversioned)
 
330
        return filter(self.is_versioned, paths)