OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 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/http/http_network_transaction.h" | 5 #include "net/http/http_network_transaction.h" |
6 | 6 |
7 #include <math.h> // ceil | 7 #include <math.h> // ceil |
8 #include <stdarg.h> | 8 #include <stdarg.h> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 12627 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
12638 } | 12638 } |
12639 | 12639 |
12640 void SetPriority(RequestPriority priority) override { priority_ = priority; } | 12640 void SetPriority(RequestPriority priority) override { priority_ = priority; } |
12641 | 12641 |
12642 bool was_npn_negotiated() const override { return false; } | 12642 bool was_npn_negotiated() const override { return false; } |
12643 | 12643 |
12644 NextProto protocol_negotiated() const override { return kProtoUnknown; } | 12644 NextProto protocol_negotiated() const override { return kProtoUnknown; } |
12645 | 12645 |
12646 bool using_spdy() const override { return false; } | 12646 bool using_spdy() const override { return false; } |
12647 | 12647 |
| 12648 const ClientSocketHandle::ConnectionAttempts& connection_attempts() |
| 12649 const override { |
| 12650 static ClientSocketHandle::ConnectionAttempts no_attempts; |
| 12651 return no_attempts; |
| 12652 } |
| 12653 |
12648 private: | 12654 private: |
12649 RequestPriority priority_; | 12655 RequestPriority priority_; |
12650 HttpStreamRequest::Delegate* const delegate_; | 12656 HttpStreamRequest::Delegate* const delegate_; |
12651 WebSocketHandshakeStreamBase::CreateHelper* websocket_stream_create_helper_; | 12657 WebSocketHandshakeStreamBase::CreateHelper* websocket_stream_create_helper_; |
12652 | 12658 |
12653 DISALLOW_COPY_AND_ASSIGN(FakeStreamRequest); | 12659 DISALLOW_COPY_AND_ASSIGN(FakeStreamRequest); |
12654 }; | 12660 }; |
12655 | 12661 |
12656 // Fake HttpStreamFactory that vends FakeStreamRequests. | 12662 // Fake HttpStreamFactory that vends FakeStreamRequests. |
12657 class FakeStreamFactory : public HttpStreamFactory { | 12663 class FakeStreamFactory : public HttpStreamFactory { |
(...skipping 1124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
13782 ASSERT_TRUE(response); | 13788 ASSERT_TRUE(response); |
13783 ASSERT_TRUE(response->headers.get()); | 13789 ASSERT_TRUE(response->headers.get()); |
13784 | 13790 |
13785 EXPECT_EQ(101, response->headers->response_code()); | 13791 EXPECT_EQ(101, response->headers->response_code()); |
13786 | 13792 |
13787 trans.reset(); | 13793 trans.reset(); |
13788 session->CloseAllConnections(); | 13794 session->CloseAllConnections(); |
13789 } | 13795 } |
13790 | 13796 |
13791 } // namespace net | 13797 } // namespace net |
OLD | NEW |