| 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 "chromeos/network/network_connection_handler_impl.h" | 5 #include "chromeos/network/network_connection_handler_impl.h" |
| 6 | 6 |
| 7 #include <map> | 7 #include <map> |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <set> | 9 #include <set> |
| 10 | 10 |
| (...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 235 result_ = error_name; | 235 result_ = error_name; |
| 236 } | 236 } |
| 237 | 237 |
| 238 std::string GetResultAndReset() { | 238 std::string GetResultAndReset() { |
| 239 std::string result; | 239 std::string result; |
| 240 result.swap(result_); | 240 result.swap(result_); |
| 241 return result; | 241 return result; |
| 242 } | 242 } |
| 243 | 243 |
| 244 void StartCertLoader() { | 244 void StartCertLoader() { |
| 245 CertLoader::Get()->StartWithNSSDB(test_nsscertdb_.get()); | 245 CertLoader::Get()->StartWithUserNSSDB(test_nsscertdb_.get()); |
| 246 base::RunLoop().RunUntilIdle(); | 246 base::RunLoop().RunUntilIdle(); |
| 247 } | 247 } |
| 248 | 248 |
| 249 void LoginToRegularUser() { | 249 void LoginToRegularUser() { |
| 250 LoginState::Get()->SetLoggedInState(LoginState::LOGGED_IN_ACTIVE, | 250 LoginState::Get()->SetLoggedInState(LoginState::LOGGED_IN_ACTIVE, |
| 251 LoginState::LOGGED_IN_USER_REGULAR); | 251 LoginState::LOGGED_IN_USER_REGULAR); |
| 252 base::RunLoop().RunUntilIdle(); | 252 base::RunLoop().RunUntilIdle(); |
| 253 } | 253 } |
| 254 | 254 |
| 255 scoped_refptr<net::X509Certificate> ImportTestClientCert() { | 255 scoped_refptr<net::X509Certificate> ImportTestClientCert() { |
| (...skipping 366 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 622 EXPECT_EQ(FakeTetherDelegate::DelegateFunctionType::NONE, | 622 EXPECT_EQ(FakeTetherDelegate::DelegateFunctionType::NONE, |
| 623 fake_tether_delegate_->last_delegate_function_type()); | 623 fake_tether_delegate_->last_delegate_function_type()); |
| 624 EXPECT_EQ(NetworkConnectionHandler::kErrorTetherAttemptWithNoDelegate, | 624 EXPECT_EQ(NetworkConnectionHandler::kErrorTetherAttemptWithNoDelegate, |
| 625 GetResultAndReset()); | 625 GetResultAndReset()); |
| 626 EXPECT_TRUE(network_connection_observer_->GetRequested(kTetherGuid)); | 626 EXPECT_TRUE(network_connection_observer_->GetRequested(kTetherGuid)); |
| 627 EXPECT_EQ(NetworkConnectionHandler::kErrorTetherAttemptWithNoDelegate, | 627 EXPECT_EQ(NetworkConnectionHandler::kErrorTetherAttemptWithNoDelegate, |
| 628 network_connection_observer_->GetResult(kTetherGuid)); | 628 network_connection_observer_->GetResult(kTetherGuid)); |
| 629 } | 629 } |
| 630 | 630 |
| 631 } // namespace chromeos | 631 } // namespace chromeos |
| OLD | NEW |