~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/transport/__init__.py

  • Committer: John Arbash Meinel
  • Date: 2006-09-05 19:53:21 UTC
  • mto: (1946.2.8 reduce-knit-churn)
  • mto: This revision was merged to the branch mainline in revision 1988.
  • Revision ID: john@arbash-meinel.com-20060905195321-167cc7f7c4b09fa0
Fix the deprecation warnings in the transport tests themselves

Show diffs side-by-side

added added

removed removed

Lines of Context:
544
544
            'bytes must be a plain string, not %s' % type(bytes)
545
545
        return self.put_file(relpath, StringIO(bytes), mode=mode)
546
546
 
 
547
    @deprecated_method(zero_eleven)
547
548
    def put_multi(self, files, mode=None, pb=None):
548
549
        """Put a set of files into the location.
549
550
 
553
554
        :return: The number of files copied.
554
555
        """
555
556
        def put(path, f):
556
 
            self.put(path, f, mode=mode)
 
557
            if isinstance(f, str):
 
558
                self.put_bytes(path, f, mode=mode)
 
559
            else:
 
560
                self.put_file(path, f, mode=mode)
557
561
        return len(self._iterate_over(files, put, pb, 'put', expand=True))
558
562
 
559
563
    def mkdir(self, relpath, mode=None):