~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/HTTPTestUtil.py

  • Committer: Vincent Ladeuil
  • Date: 2007-03-14 08:12:20 UTC
  • mto: (2323.7.1 redirection)
  • mto: This revision was merged to the branch mainline in revision 2390.
  • Revision ID: v.ladeuil+lp@free.fr-20070314081220-b7rce9vi16r9yd0b
TestingHTTPServer.test_case_server renamed from test_case to avoid confusions.

Show diffs side-by-side

added added

removed removed

Lines of Context:
120
120
        """Hand the request off to a smart server instance."""
121
121
        self.send_response(200)
122
122
        self.send_header("Content-type", "application/octet-stream")
123
 
        transport = get_transport(self.server.test_case._home_dir)
 
123
        transport = get_transport(self.server.test_case_server._home_dir)
124
124
        # TODO: We might like to support streaming responses.  1.0 allows no
125
125
        # Content-length in this case, so for integrity we should perform our
126
126
        # own chunking within the stream.
232
232
        """Redirect a single HTTP request to another host"""
233
233
        valid = TestingHTTPRequestHandler.parse_request(self)
234
234
        if valid:
235
 
            rhost, rport = self.server.test_case.redirected_to_address()
 
235
            rhost, rport = self.server.test_case_server.redirected_to_address()
236
236
            if rhost is not None and rport is not None:
237
237
                # Just redirect permanently
238
238
                self.send_response(301)