| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 "base/file_util.h" | 5 #include "base/file_util.h" |
| 6 #include "base/path_service.h" | 6 #include "base/path_service.h" |
| 7 #include "base/string_util.h" | 7 #include "base/string_util.h" |
| 8 #include "base/utf_string_conversions.h" | 8 #include "base/utf_string_conversions.h" |
| 9 #include "googleurl/src/gurl.h" | 9 #include "googleurl/src/gurl.h" |
| 10 #include "net/base/net_log_unittest.h" | 10 #include "net/base/net_log_unittest.h" |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 } | 55 } |
| 56 | 56 |
| 57 virtual void OnError(int line_number, const string16& message) { | 57 virtual void OnError(int line_number, const string16& message) { |
| 58 // Helpful when debugging. | 58 // Helpful when debugging. |
| 59 LOG(INFO) << "PAC-error: [" << line_number << "] " << message; | 59 LOG(INFO) << "PAC-error: [" << line_number << "] " << message; |
| 60 | 60 |
| 61 errors.push_back(UTF16ToUTF8(message)); | 61 errors.push_back(UTF16ToUTF8(message)); |
| 62 errors_line_number.push_back(line_number); | 62 errors_line_number.push_back(line_number); |
| 63 } | 63 } |
| 64 | 64 |
| 65 virtual void Shutdown() {} |
| 66 |
| 65 // Mock values to return. | 67 // Mock values to return. |
| 66 std::string my_ip_address_result; | 68 std::string my_ip_address_result; |
| 67 std::string my_ip_address_ex_result; | 69 std::string my_ip_address_ex_result; |
| 68 std::string dns_resolve_result; | 70 std::string dns_resolve_result; |
| 69 std::string dns_resolve_ex_result; | 71 std::string dns_resolve_ex_result; |
| 70 | 72 |
| 71 // Inputs we got called with. | 73 // Inputs we got called with. |
| 72 std::vector<std::string> alerts; | 74 std::vector<std::string> alerts; |
| 73 std::vector<std::string> errors; | 75 std::vector<std::string> errors; |
| 74 std::vector<int> errors_line_number; | 76 std::vector<int> errors_line_number; |
| (...skipping 492 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 567 | 569 |
| 568 ASSERT_EQ(1u, bindings->dns_resolves.size()); | 570 ASSERT_EQ(1u, bindings->dns_resolves.size()); |
| 569 EXPECT_EQ("xn--bcher-kva.ch", bindings->dns_resolves[0]); | 571 EXPECT_EQ("xn--bcher-kva.ch", bindings->dns_resolves[0]); |
| 570 | 572 |
| 571 ASSERT_EQ(1u, bindings->dns_resolves_ex.size()); | 573 ASSERT_EQ(1u, bindings->dns_resolves_ex.size()); |
| 572 EXPECT_EQ("xn--bcher-kva.ch", bindings->dns_resolves_ex[0]); | 574 EXPECT_EQ("xn--bcher-kva.ch", bindings->dns_resolves_ex[0]); |
| 573 } | 575 } |
| 574 | 576 |
| 575 } // namespace | 577 } // namespace |
| 576 } // namespace net | 578 } // namespace net |
| OLD | NEW |