| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 6455 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6466 HostPortPair("myproxy", 80)); | 6466 HostPortPair("myproxy", 80)); |
| 6467 results->UseProxyServer(proxy_server); | 6467 results->UseProxyServer(proxy_server); |
| 6468 resolved_.push_back(url); | 6468 resolved_.push_back(url); |
| 6469 return OK; | 6469 return OK; |
| 6470 } | 6470 } |
| 6471 | 6471 |
| 6472 virtual void CancelRequest(RequestHandle request) { | 6472 virtual void CancelRequest(RequestHandle request) { |
| 6473 NOTREACHED(); | 6473 NOTREACHED(); |
| 6474 } | 6474 } |
| 6475 | 6475 |
| 6476 virtual void CancelSetPacScript() { |
| 6477 NOTREACHED(); |
| 6478 } |
| 6479 |
| 6476 virtual int SetPacScript(const scoped_refptr<ProxyResolverScriptData>&, | 6480 virtual int SetPacScript(const scoped_refptr<ProxyResolverScriptData>&, |
| 6477 CompletionCallback* /*callback*/) { | 6481 CompletionCallback* /*callback*/) { |
| 6478 return OK; | 6482 return OK; |
| 6479 } | 6483 } |
| 6480 | 6484 |
| 6481 const std::vector<GURL>& resolved() const { return resolved_; } | 6485 const std::vector<GURL>& resolved() const { return resolved_; } |
| 6482 | 6486 |
| 6483 private: | 6487 private: |
| 6484 std::vector<GURL> resolved_; | 6488 std::vector<GURL> resolved_; |
| 6485 | 6489 |
| (...skipping 1472 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7958 rv = callback.WaitForResult(); | 7962 rv = callback.WaitForResult(); |
| 7959 ASSERT_EQ(OK, rv); | 7963 ASSERT_EQ(OK, rv); |
| 7960 | 7964 |
| 7961 std::string contents; | 7965 std::string contents; |
| 7962 rv = ReadTransaction(trans.get(), &contents); | 7966 rv = ReadTransaction(trans.get(), &contents); |
| 7963 EXPECT_EQ(net::OK, rv); | 7967 EXPECT_EQ(net::OK, rv); |
| 7964 EXPECT_EQ("hello world", contents); | 7968 EXPECT_EQ("hello world", contents); |
| 7965 } | 7969 } |
| 7966 | 7970 |
| 7967 } // namespace net | 7971 } // namespace net |
| OLD | NEW |