| Index: net/tools/quic/test_tools/quic_test_client.h
|
| diff --git a/net/tools/quic/test_tools/quic_test_client.h b/net/tools/quic/test_tools/quic_test_client.h
|
| index cb76d56683f74daf5107b06727bd04d04dfb88e8..dcc73a0c95da528780b8470e7ce5f65061609f89 100644
|
| --- a/net/tools/quic/test_tools/quic_test_client.h
|
| +++ b/net/tools/quic/test_tools/quic_test_client.h
|
| @@ -19,7 +19,6 @@
|
| #include "net/quic/core/quic_framer.h"
|
| #include "net/quic/core/quic_packet_creator.h"
|
| #include "net/quic/core/quic_protocol.h"
|
| -#include "net/tools/balsa/balsa_frame.h"
|
| #include "net/tools/epoll_server/epoll_server.h"
|
| #include "net/tools/quic/quic_client.h"
|
| #include "testing/gmock/include/gmock/gmock.h"
|
| @@ -129,8 +128,21 @@ class QuicTestClient : public QuicSpdyStream::Visitor,
|
| // set the response_listener on the client().
|
| void SendRequestsAndWaitForResponses(
|
| const std::vector<std::string>& url_list);
|
| - ssize_t SendMessage(const HTTPMessage& message);
|
| - std::string SendCustomSynchronousRequest(const HTTPMessage& message);
|
| + // Sends a request containing |headers| and |body| and returns the number of
|
| + // bytes sent (the size of the serialized request headers and body).
|
| + ssize_t SendMessage(const SpdyHeaderBlock& headers, base::StringPiece body);
|
| + // Sends a request containing |headers| and |body| with the fin bit set to
|
| + // |fin| and returns the number of bytes sent (the size of the serialized
|
| + // request headers and body).
|
| + ssize_t SendMessage(const SpdyHeaderBlock& headers,
|
| + base::StringPiece body,
|
| + bool fin);
|
| + // Sends a request containing |headers| and |body|, waits for the response,
|
| + // and returns the response body.
|
| + std::string SendCustomSynchronousRequest(const SpdyHeaderBlock& headers,
|
| + const std::string& body);
|
| + // Sends a GET request for |uri|, waits for the response, and returns the
|
| + // response body.
|
| std::string SendSynchronousRequest(const std::string& uri);
|
| void Connect();
|
| void ResetConnection();
|
| @@ -206,8 +218,8 @@ class QuicTestClient : public QuicSpdyStream::Visitor,
|
| // Calls GetOrCreateStream(), sends the request on the stream, and
|
| // stores the request in case it needs to be resent. If |headers| is
|
| // null, only the body will be sent on the stream.
|
| - ssize_t GetOrCreateStreamAndSendRequest(const BalsaHeaders* headers,
|
| - StringPiece body,
|
| + ssize_t GetOrCreateStreamAndSendRequest(const SpdyHeaderBlock* headers,
|
| + base::StringPiece body,
|
| bool fin,
|
| QuicAckListenerInterface* delegate);
|
|
|
| @@ -284,8 +296,11 @@ class QuicTestClient : public QuicSpdyStream::Visitor,
|
| QuicAckListenerInterface* delegate_;
|
| };
|
|
|
| - // Given a uri, creates a simple HTTPMessage request message for testing.
|
| - static void FillInRequest(const std::string& uri, HTTPMessage* message);
|
| + // Given |uri|, populates the fields in |headers| for a simple GET
|
| + // request. If |uri| is a relative URL, the QuicServerId will be
|
| + // use to specify the authority.
|
| + bool PopulateHeaderBlockFromUrl(const std::string& uri,
|
| + SpdyHeaderBlock* headers);
|
|
|
| bool HaveActiveStream();
|
|
|
|
|