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

Side by Side Diff: net/spdy/spdy_session_pool_unittest.cc

Issue 987123002: Advertise HTTP/2 support. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 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/spdy/spdy_proxy_client_socket_unittest.cc ('k') | net/spdy/spdy_session_unittest.cc » ('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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 "net/spdy/spdy_session_pool.h" 5 #include "net/spdy/spdy_session_pool.h"
6 6
7 #include <cstddef> 7 #include <cstddef>
8 #include <string> 8 #include <string>
9 9
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 void RunIPPoolingTest(SpdyPoolCloseSessionsType close_sessions_type); 44 void RunIPPoolingTest(SpdyPoolCloseSessionsType close_sessions_type);
45 45
46 SpdySessionDependencies session_deps_; 46 SpdySessionDependencies session_deps_;
47 scoped_refptr<HttpNetworkSession> http_session_; 47 scoped_refptr<HttpNetworkSession> http_session_;
48 SpdySessionPool* spdy_session_pool_; 48 SpdySessionPool* spdy_session_pool_;
49 }; 49 };
50 50
51 INSTANTIATE_TEST_CASE_P( 51 INSTANTIATE_TEST_CASE_P(
52 NextProto, 52 NextProto,
53 SpdySessionPoolTest, 53 SpdySessionPoolTest,
54 testing::Values(kProtoSPDY31, kProtoSPDY4_14, kProtoSPDY4_15)); 54 testing::Values(kProtoSPDY31, kProtoSPDY4_14, kProtoSPDY4_15, kProtoSPDY4));
55 55
56 // A delegate that opens a new session when it is closed. 56 // A delegate that opens a new session when it is closed.
57 class SessionOpeningDelegate : public SpdyStream::Delegate { 57 class SessionOpeningDelegate : public SpdyStream::Delegate {
58 public: 58 public:
59 SessionOpeningDelegate(SpdySessionPool* spdy_session_pool, 59 SessionOpeningDelegate(SpdySessionPool* spdy_session_pool,
60 const SpdySessionKey& key) 60 const SpdySessionKey& key)
61 : spdy_session_pool_(spdy_session_pool), 61 : spdy_session_pool_(spdy_session_pool),
62 key_(key) {} 62 key_(key) {}
63 63
64 ~SessionOpeningDelegate() override {} 64 ~SessionOpeningDelegate() override {}
(...skipping 545 matching lines...) Expand 10 before | Expand all | Expand 10 after
610 EXPECT_TRUE(delegateA.StreamIsClosed()); 610 EXPECT_TRUE(delegateA.StreamIsClosed());
611 EXPECT_EQ(ERR_NETWORK_CHANGED, delegateA.WaitForClose()); 611 EXPECT_EQ(ERR_NETWORK_CHANGED, delegateA.WaitForClose());
612 EXPECT_TRUE(delegateB.StreamIsClosed()); 612 EXPECT_TRUE(delegateB.StreamIsClosed());
613 EXPECT_EQ(ERR_NETWORK_CHANGED, delegateB.WaitForClose()); 613 EXPECT_EQ(ERR_NETWORK_CHANGED, delegateB.WaitForClose());
614 #endif // defined(OS_ANDROID) || defined(OS_WIN) || defined(OS_IOS) 614 #endif // defined(OS_ANDROID) || defined(OS_WIN) || defined(OS_IOS)
615 } 615 }
616 616
617 } // namespace 617 } // namespace
618 618
619 } // namespace net 619 } // namespace net
OLDNEW
« no previous file with comments | « net/spdy/spdy_proxy_client_socket_unittest.cc ('k') | net/spdy/spdy_session_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698