Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1946)

Side by Side Diff: chromeos/network/auto_connect_handler_unittest.cc

Issue 1431563005: Handle prohibited technologies in device policy ONC (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « chromeos/chromeos.gyp ('k') | chromeos/network/client_cert_resolver_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 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 "chromeos/network/auto_connect_handler.h" 5 #include "chromeos/network/auto_connect_handler.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 network_config_handler_.reset( 114 network_config_handler_.reset(
115 NetworkConfigurationHandler::InitializeForTest( 115 NetworkConfigurationHandler::InitializeForTest(
116 network_state_handler_.get(), NULL /* network_device_handler */)); 116 network_state_handler_.get(), NULL /* network_device_handler */));
117 117
118 network_profile_handler_.reset(new NetworkProfileHandler()); 118 network_profile_handler_.reset(new NetworkProfileHandler());
119 network_profile_handler_->Init(); 119 network_profile_handler_->Init();
120 120
121 managed_config_handler_.reset(new ManagedNetworkConfigurationHandlerImpl()); 121 managed_config_handler_.reset(new ManagedNetworkConfigurationHandlerImpl());
122 managed_config_handler_->Init( 122 managed_config_handler_->Init(
123 network_state_handler_.get(), network_profile_handler_.get(), 123 network_state_handler_.get(), network_profile_handler_.get(),
124 network_config_handler_.get(), nullptr /* network_device_handler */); 124 network_config_handler_.get(), nullptr /* network_device_handler */,
125 nullptr /* prohibited_technologies_handler */);
125 126
126 client_cert_resolver_.reset(new ClientCertResolver()); 127 client_cert_resolver_.reset(new ClientCertResolver());
127 client_cert_resolver_->Init(network_state_handler_.get(), 128 client_cert_resolver_->Init(network_state_handler_.get(),
128 managed_config_handler_.get()); 129 managed_config_handler_.get());
129 client_cert_resolver_->SetSlowTaskRunnerForTest( 130 client_cert_resolver_->SetSlowTaskRunnerForTest(
130 message_loop_.task_runner()); 131 message_loop_.task_runner());
131 132
132 auto_connect_handler_.reset(new AutoConnectHandler()); 133 auto_connect_handler_.reset(new AutoConnectHandler());
133 auto_connect_handler_->Init(client_cert_resolver_.get(), 134 auto_connect_handler_->Init(client_cert_resolver_.get(),
134 nullptr, // no connection handler 135 nullptr, // no connection handler
(...skipping 335 matching lines...) Expand 10 before | Expand all | Expand 10 after
470 // Applying the user policy after login would usually trigger connecting to 471 // Applying the user policy after login would usually trigger connecting to
471 // the 'best' network. But the manual connect prevents this. 472 // the 'best' network. But the manual connect prevents this.
472 SetupPolicy(std::string(), // no network configs 473 SetupPolicy(std::string(), // no network configs
473 base::DictionaryValue(), // no global config 474 base::DictionaryValue(), // no global config
474 true); // load as user policy 475 true); // load as user policy
475 EXPECT_EQ(shill::kStateOnline, GetServiceState("wifi0")); 476 EXPECT_EQ(shill::kStateOnline, GetServiceState("wifi0"));
476 EXPECT_EQ(shill::kStateIdle, GetServiceState("wifi1")); 477 EXPECT_EQ(shill::kStateIdle, GetServiceState("wifi1"));
477 } 478 }
478 479
479 } // namespace chromeos 480 } // namespace chromeos
OLDNEW
« no previous file with comments | « chromeos/chromeos.gyp ('k') | chromeos/network/client_cert_resolver_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698