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

Side by Side Diff: net/tools/quic/end_to_end_test.cc

Issue 2363393004: Remove usage of BalsaHeaders from QuicClient. Also move QuicDataToResend from QuicClient to QuicCli… (Closed)
Patch Set: Fix win Created 4 years, 2 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 unified diff | Download patch
« no previous file with comments | « net/quic/core/spdy_utils_test.cc ('k') | net/tools/quic/quic_client.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <stddef.h> 5 #include <stddef.h>
6 #include <sys/epoll.h> 6 #include <sys/epoll.h>
7 7
8 #include <list> 8 #include <list>
9 #include <memory> 9 #include <memory>
10 #include <string> 10 #include <string>
(...skipping 1850 matching lines...) Expand 10 before | Expand all | Expand 10 after
1861 // Object is ref counted. 1861 // Object is ref counted.
1862 ~TestAckListener() override { EXPECT_EQ(0, num_notifications_); } 1862 ~TestAckListener() override { EXPECT_EQ(0, num_notifications_); }
1863 1863
1864 private: 1864 private:
1865 int num_notifications_; 1865 int num_notifications_;
1866 }; 1866 };
1867 1867
1868 class TestResponseListener : public QuicClient::ResponseListener { 1868 class TestResponseListener : public QuicClient::ResponseListener {
1869 public: 1869 public:
1870 void OnCompleteResponse(QuicStreamId id, 1870 void OnCompleteResponse(QuicStreamId id,
1871 const BalsaHeaders& response_headers, 1871 const SpdyHeaderBlock& response_headers,
1872 const string& response_body) override { 1872 const string& response_body) override {
1873 string debug_string; 1873 string debug_string = response_headers.DebugString();
1874 response_headers.DumpHeadersToString(&debug_string);
1875 DVLOG(1) << "response for stream " << id << " " << debug_string << "\n" 1874 DVLOG(1) << "response for stream " << id << " " << debug_string << "\n"
1876 << response_body; 1875 << response_body;
1877 } 1876 }
1878 }; 1877 };
1879 1878
1880 TEST_P(EndToEndTest, AckNotifierWithPacketLossAndBlockedSocket) { 1879 TEST_P(EndToEndTest, AckNotifierWithPacketLossAndBlockedSocket) {
1881 // Verify that even in the presence of packet loss and occasionally blocked 1880 // Verify that even in the presence of packet loss and occasionally blocked
1882 // socket, an AckNotifierDelegate will get informed that the data it is 1881 // socket, an AckNotifierDelegate will get informed that the data it is
1883 // interested in has been ACKed. This tests end-to-end ACK notification, and 1882 // interested in has been ACKed. This tests end-to-end ACK notification, and
1884 // demonstrates that retransmissions do not break this functionality. 1883 // demonstrates that retransmissions do not break this functionality.
(...skipping 1043 matching lines...) Expand 10 before | Expand all | Expand 10 after
2928 EXPECT_EQ(kBarResponseBody, client_->response_body()); 2927 EXPECT_EQ(kBarResponseBody, client_->response_body());
2929 QuicConnectionStats client_stats = 2928 QuicConnectionStats client_stats =
2930 client_->client()->session()->connection()->GetStats(); 2929 client_->client()->session()->connection()->GetStats();
2931 EXPECT_EQ(0u, client_stats.packets_lost); 2930 EXPECT_EQ(0u, client_stats.packets_lost);
2932 EXPECT_EQ(1, client_->client()->GetNumSentClientHellos()); 2931 EXPECT_EQ(1, client_->client()->GetNumSentClientHellos());
2933 } 2932 }
2934 2933
2935 } // namespace 2934 } // namespace
2936 } // namespace test 2935 } // namespace test
2937 } // namespace net 2936 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/core/spdy_utils_test.cc ('k') | net/tools/quic/quic_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698