~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/HttpServer.py

  • Committer: Robert Collins
  • Date: 2007-03-28 13:33:58 UTC
  • mto: (2018.5.115 hpss)
  • mto: This revision was merged to the branch mainline in revision 2383.
  • Revision ID: robertc@robertcollins.net-20070328133358-wn7wgnzmb0cjohjk
Fixup the test changes made for hpss to be clean and self contained.

Show diffs side-by-side

added added

removed removed

Lines of Context:
29
29
import urlparse
30
30
 
31
31
from bzrlib.transport import Server
 
32
from bzrlib.transport.local import LocalURLServer
32
33
 
33
34
 
34
35
class WebserverNotAvailable(Exception):
304
305
        """Capture Server log output."""
305
306
        self.logs.append(format % args)
306
307
 
307
 
    def setUp(self, decorated_transport=None):
 
308
    def setUp(self, backing_transport_server=None):
308
309
        """See bzrlib.transport.Server.setUp.
309
310
        
310
 
        :param decorated_transport: The transport that requests over this
 
311
        :param backing_transport_server: The transport that requests over this
311
312
            protocol should be forwarded to. Note that this is currently not
312
 
            supported for HTTP - it is ignored.
 
313
            supported for HTTP.
313
314
        """
 
315
        # XXX: TODO: make the server back onto vfs_server rather than local
 
316
        # disk.
 
317
        assert backing_transport_server is None or \
 
318
            isinstance(backing_transport_server, LocalURLServer), \
 
319
            "HTTPServer currently assumes local transport, got %s" % \
 
320
            backing_transport_server
314
321
        self._home_dir = os.getcwdu()
315
322
        self._local_path_parts = self._home_dir.split(os.path.sep)
316
323
        self._http_starting = threading.Lock()