| OLD | NEW |
| 1 // Copyright (c) 2014 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2014 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/base/network_change_notifier.h" | 5 #include "net/base/network_change_notifier.h" |
| 6 | 6 |
| 7 #include "net/base/net_util.h" | 7 #include "net/base/network_interfaces.h" |
| 8 #include "testing/gtest/include/gtest/gtest.h" | 8 #include "testing/gtest/include/gtest/gtest.h" |
| 9 | 9 |
| 10 namespace net { | 10 namespace net { |
| 11 | 11 |
| 12 // Note: This test is subject to the host's OS and network connection. This test | 12 // Note: This test is subject to the host's OS and network connection. This test |
| 13 // is not future-proof. New standards will come about necessitating the need to | 13 // is not future-proof. New standards will come about necessitating the need to |
| 14 // alter the ranges of these tests. | 14 // alter the ranges of these tests. |
| 15 TEST(NetworkChangeNotifierTest, NetMaxBandwidthRange) { | 15 TEST(NetworkChangeNotifierTest, NetMaxBandwidthRange) { |
| 16 NetworkChangeNotifier::ConnectionType connection_type = | 16 NetworkChangeNotifier::ConnectionType connection_type = |
| 17 NetworkChangeNotifier::GetConnectionType(); | 17 NetworkChangeNotifier::GetConnectionType(); |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 115 interface_vmnet_win.type = NetworkChangeNotifier::CONNECTION_ETHERNET; | 115 interface_vmnet_win.type = NetworkChangeNotifier::CONNECTION_ETHERNET; |
| 116 interface_vmnet_win.name = "virtualdevice"; | 116 interface_vmnet_win.name = "virtualdevice"; |
| 117 interface_vmnet_win.friendly_name = "VMware Network Adapter VMnet1"; | 117 interface_vmnet_win.friendly_name = "VMware Network Adapter VMnet1"; |
| 118 list.push_back(interface_vmnet_win); | 118 list.push_back(interface_vmnet_win); |
| 119 | 119 |
| 120 EXPECT_EQ(NetworkChangeNotifier::CONNECTION_NONE, | 120 EXPECT_EQ(NetworkChangeNotifier::CONNECTION_NONE, |
| 121 NetworkChangeNotifier::ConnectionTypeFromInterfaceList(list)); | 121 NetworkChangeNotifier::ConnectionTypeFromInterfaceList(list)); |
| 122 } | 122 } |
| 123 | 123 |
| 124 } // namespace net | 124 } // namespace net |
| OLD | NEW |