Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(437)

Unified Diff: net/quic/test_tools/quic_test_utils.cc

Issue 2901773004: Landing Recent QUIC changes until May 20, 2017. (Closed)
Patch Set: Disable quic_restart_flag_quic_big_endian_connection_id_server until tests can be fixed. Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/quic/test_tools/quic_test_utils.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/test_tools/quic_test_utils.cc
diff --git a/net/quic/test_tools/quic_test_utils.cc b/net/quic/test_tools/quic_test_utils.cc
index 7aff53725243cab7fafd0695b8f95c07bb4d5c4a..e06f2664cfadf1a469e91a6c2ac5eab7318e754b 100644
--- a/net/quic/test_tools/quic_test_utils.cc
+++ b/net/quic/test_tools/quic_test_utils.cc
@@ -334,6 +334,10 @@ void MockQuicConnection::AdvanceTime(QuicTime::Delta delta) {
static_cast<MockQuicConnectionHelper*>(helper())->AdvanceTime(delta);
}
+bool MockQuicConnection::OnProtocolVersionMismatch(QuicVersion version) {
+ return false;
+}
+
PacketSavingConnection::PacketSavingConnection(MockQuicConnectionHelper* helper,
MockAlarmFactory* alarm_factory,
Perspective perspective)
@@ -373,6 +377,14 @@ MockQuicSession::~MockQuicSession() {
delete connection();
}
+QuicCryptoStream* MockQuicSession::GetMutableCryptoStream() {
+ return crypto_stream_.get();
+}
+
+const QuicCryptoStream* MockQuicSession::GetCryptoStream() const {
+ return crypto_stream_.get();
+}
+
// static
QuicConsumedData MockQuicSession::ConsumeAllData(
QuicStream* /*stream*/,
@@ -397,6 +409,24 @@ MockQuicSpdySession::~MockQuicSpdySession() {
delete connection();
}
+QuicCryptoStream* MockQuicSpdySession::GetMutableCryptoStream() {
+ return crypto_stream_.get();
+}
+
+const QuicCryptoStream* MockQuicSpdySession::GetCryptoStream() const {
+ return crypto_stream_.get();
+}
+
+size_t MockQuicSpdySession::WriteHeaders(
+ QuicStreamId id,
+ SpdyHeaderBlock headers,
+ bool fin,
+ SpdyPriority priority,
+ QuicReferenceCountedPointer<QuicAckListenerInterface> ack_listener) {
+ write_headers_ = std::move(headers);
+ return WriteHeadersMock(id, write_headers_, fin, priority, ack_listener);
+}
+
TestQuicSpdyServerSession::TestQuicSpdyServerSession(
QuicConnection* connection,
const QuicConfig& config,
@@ -614,7 +644,6 @@ QuicEncryptedPacket* ConstructEncryptedPacket(
header.public_header.connection_id = connection_id;
header.public_header.connection_id_length = connection_id_length;
header.public_header.version_flag = version_flag;
- header.public_header.multipath_flag = false;
header.public_header.reset_flag = reset_flag;
header.public_header.packet_number_length = packet_number_length;
header.packet_number = packet_number;
« no previous file with comments | « net/quic/test_tools/quic_test_utils.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698