| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 <iostream> | 5 #include <iostream> |
| 6 #include <memory> | 6 #include <memory> |
| 7 #include <sstream> | 7 #include <sstream> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
| (...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 250 &ShillProfileTestClient::GetProperties)); | 250 &ShillProfileTestClient::GetProperties)); |
| 251 | 251 |
| 252 ON_CALL(*mock_profile_client_, GetEntry(_,_,_,_)) | 252 ON_CALL(*mock_profile_client_, GetEntry(_,_,_,_)) |
| 253 .WillByDefault(Invoke(&profiles_stub_, | 253 .WillByDefault(Invoke(&profiles_stub_, |
| 254 &ShillProfileTestClient::GetEntry)); | 254 &ShillProfileTestClient::GetEntry)); |
| 255 | 255 |
| 256 ON_CALL(*mock_service_client_, GetProperties(_,_)) | 256 ON_CALL(*mock_service_client_, GetProperties(_,_)) |
| 257 .WillByDefault(Invoke(&services_stub_, | 257 .WillByDefault(Invoke(&services_stub_, |
| 258 &ShillServiceTestClient::GetProperties)); | 258 &ShillServiceTestClient::GetProperties)); |
| 259 | 259 |
| 260 network_state_handler_.reset(NetworkStateHandler::InitializeForTest()); | 260 network_state_handler_ = NetworkStateHandler::InitializeForTest(); |
| 261 network_profile_handler_.reset(new TestNetworkProfileHandler()); | 261 network_profile_handler_.reset(new TestNetworkProfileHandler()); |
| 262 network_configuration_handler_.reset( | 262 network_configuration_handler_.reset( |
| 263 NetworkConfigurationHandler::InitializeForTest( | 263 NetworkConfigurationHandler::InitializeForTest( |
| 264 network_state_handler_.get(), | 264 network_state_handler_.get(), |
| 265 nullptr /* no NetworkDeviceHandler */)); | 265 nullptr /* no NetworkDeviceHandler */)); |
| 266 managed_network_configuration_handler_.reset( | 266 managed_network_configuration_handler_.reset( |
| 267 new ManagedNetworkConfigurationHandlerImpl()); | 267 new ManagedNetworkConfigurationHandlerImpl()); |
| 268 managed_network_configuration_handler_->Init( | 268 managed_network_configuration_handler_->Init( |
| 269 network_state_handler_.get(), network_profile_handler_.get(), | 269 network_state_handler_.get(), network_profile_handler_.get(), |
| 270 network_configuration_handler_.get(), nullptr /* no DeviceHandler */, | 270 network_configuration_handler_.get(), nullptr /* no DeviceHandler */, |
| (...skipping 707 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 978 EXPECT_CALL(*mock_profile_client_, | 978 EXPECT_CALL(*mock_profile_client_, |
| 979 GetProperties(dbus::ObjectPath(kUser1ProfilePath), _, _)); | 979 GetProperties(dbus::ObjectPath(kUser1ProfilePath), _, _)); |
| 980 | 980 |
| 981 SetPolicy(::onc::ONC_SOURCE_USER_POLICY, kUser1, "policy/policy_wifi1.onc"); | 981 SetPolicy(::onc::ONC_SOURCE_USER_POLICY, kUser1, "policy/policy_wifi1.onc"); |
| 982 managed_network_configuration_handler_->RemoveObserver(&policy_observer_); | 982 managed_network_configuration_handler_->RemoveObserver(&policy_observer_); |
| 983 managed_network_configuration_handler_.reset(); | 983 managed_network_configuration_handler_.reset(); |
| 984 base::RunLoop().RunUntilIdle(); | 984 base::RunLoop().RunUntilIdle(); |
| 985 } | 985 } |
| 986 | 986 |
| 987 } // namespace chromeos | 987 } // namespace chromeos |
| OLD | NEW |