OLD | NEW |
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 "chrome/browser/net/dns_probe_service.h" | 5 #include "chrome/browser/net/dns_probe_service.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
9 #include "base/memory/weak_ptr.h" | 9 #include "base/memory/weak_ptr.h" |
10 #include "base/message_loop/message_loop.h" | 10 #include "base/message_loop/message_loop.h" |
11 #include "base/run_loop.h" | 11 #include "base/run_loop.h" |
12 #include "chrome/browser/net/dns_probe_runner.h" | 12 #include "chrome/browser/net/dns_probe_runner.h" |
13 #include "chrome/browser/net/dns_probe_test_util.h" | 13 #include "chrome/browser/net/dns_probe_test_util.h" |
14 #include "chrome/common/net/net_error_info.h" | 14 #include "components/error_page/common/net_error_info.h" |
15 #include "content/public/test/test_browser_thread_bundle.h" | 15 #include "content/public/test/test_browser_thread_bundle.h" |
16 #include "net/dns/dns_test_util.h" | 16 #include "net/dns/dns_test_util.h" |
17 #include "testing/gtest/include/gtest/gtest.h" | 17 #include "testing/gtest/include/gtest/gtest.h" |
18 | 18 |
19 using base::MessageLoopForIO; | 19 using base::MessageLoopForIO; |
20 using base::RunLoop; | 20 using base::RunLoop; |
21 using chrome_common_net::DnsProbeStatus; | 21 using chrome_common_net::DnsProbeStatus; |
22 using content::TestBrowserThreadBundle; | 22 using content::TestBrowserThreadBundle; |
23 using net::MockDnsClientRule; | 23 using net::MockDnsClientRule; |
24 | 24 |
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
124 // Pretend cache expires. | 124 // Pretend cache expires. |
125 ClearCachedResult(); | 125 ClearCachedResult(); |
126 // New rules should apply, since a new probe should be run. | 126 // New rules should apply, since a new probe should be run. |
127 RunTest(MockDnsClientRule::TIMEOUT, MockDnsClientRule::TIMEOUT, | 127 RunTest(MockDnsClientRule::TIMEOUT, MockDnsClientRule::TIMEOUT, |
128 chrome_common_net::DNS_PROBE_FINISHED_NO_INTERNET); | 128 chrome_common_net::DNS_PROBE_FINISHED_NO_INTERNET); |
129 } | 129 } |
130 | 130 |
131 } // namespace | 131 } // namespace |
132 | 132 |
133 } // namespace chrome_browser_net | 133 } // namespace chrome_browser_net |
OLD | NEW |