| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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/download/internal/scheduler/network_listener.h" | 5 #include "components/download/internal/scheduler/network_listener.h" |
| 6 | 6 |
| 7 #include "base/memory/ptr_util.h" | 7 #include "base/memory/ptr_util.h" |
| 8 #include "base/message_loop/message_loop.h" |
| 8 #include "base/run_loop.h" | 9 #include "base/run_loop.h" |
| 9 #include "testing/gmock/include/gmock/gmock.h" | 10 #include "testing/gmock/include/gmock/gmock.h" |
| 10 #include "testing/gtest/include/gtest/gtest.h" | 11 #include "testing/gtest/include/gtest/gtest.h" |
| 11 | 12 |
| 12 using ConnectionTypeObserver = | 13 using ConnectionTypeObserver = |
| 13 net::NetworkChangeNotifier::ConnectionTypeObserver; | 14 net::NetworkChangeNotifier::ConnectionTypeObserver; |
| 14 using ConnectionType = net::NetworkChangeNotifier::ConnectionType; | 15 using ConnectionType = net::NetworkChangeNotifier::ConnectionType; |
| 15 | 16 |
| 16 namespace download { | 17 namespace download { |
| 17 namespace { | 18 namespace { |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 90 OnNetworkChange(NetworkListener::NetworkStatus::UNMETERED)) | 91 OnNetworkChange(NetworkListener::NetworkStatus::UNMETERED)) |
| 91 .Times(1) | 92 .Times(1) |
| 92 .RetiresOnSaturation(); | 93 .RetiresOnSaturation(); |
| 93 | 94 |
| 94 ChangeNetworkType(ConnectionType::CONNECTION_WIFI); | 95 ChangeNetworkType(ConnectionType::CONNECTION_WIFI); |
| 95 ChangeNetworkType(ConnectionType::CONNECTION_ETHERNET); | 96 ChangeNetworkType(ConnectionType::CONNECTION_ETHERNET); |
| 96 } | 97 } |
| 97 | 98 |
| 98 } // namespace | 99 } // namespace |
| 99 } // namespace download | 100 } // namespace download |
| OLD | NEW |