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 "components/captive_portal/captive_portal_detector.h" | 5 #include "components/captive_portal/captive_portal_detector.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
11 #include "base/memory/ref_counted.h" | 11 #include "base/memory/ref_counted.h" |
12 #include "base/run_loop.h" | 12 #include "base/run_loop.h" |
13 #include "base/thread_task_runner_handle.h" | 13 #include "base/threading/thread_task_runner_handle.h" |
14 #include "base/time/time.h" | 14 #include "base/time/time.h" |
15 #include "components/captive_portal/captive_portal_testing_utils.h" | 15 #include "components/captive_portal/captive_portal_testing_utils.h" |
16 #include "net/base/net_errors.h" | 16 #include "net/base/net_errors.h" |
17 #include "net/url_request/url_request_test_util.h" | 17 #include "net/url_request/url_request_test_util.h" |
18 #include "testing/gtest/include/gtest/gtest.h" | 18 #include "testing/gtest/include/gtest/gtest.h" |
19 #include "url/gurl.h" | 19 #include "url/gurl.h" |
20 | 20 |
21 namespace captive_portal { | 21 namespace captive_portal { |
22 | 22 |
23 namespace { | 23 namespace { |
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
203 | 203 |
204 TEST_F(CaptivePortalDetectorTest, Cancel) { | 204 TEST_F(CaptivePortalDetectorTest, Cancel) { |
205 RunCancelTest(); | 205 RunCancelTest(); |
206 CaptivePortalDetector::Results results; | 206 CaptivePortalDetector::Results results; |
207 results.result = captive_portal::RESULT_INTERNET_CONNECTED; | 207 results.result = captive_portal::RESULT_INTERNET_CONNECTED; |
208 results.response_code = 204; | 208 results.response_code = 204; |
209 RunTest(results, net::OK, 204, NULL); | 209 RunTest(results, net::OK, 204, NULL); |
210 } | 210 } |
211 | 211 |
212 } // namespace captive_portal | 212 } // namespace captive_portal |
OLD | NEW |