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

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

Issue 477663004: Merged FakedDBusThreadManager with DBusThreadManager. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 3 months 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 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 #include "chromeos/network/client_cert_resolver.h" 4 #include "chromeos/network/client_cert_resolver.h"
5 5
6 #include <cert.h> 6 #include <cert.h>
7 #include <pk11pub.h> 7 #include <pk11pub.h>
8 8
9 #include "base/file_util.h" 9 #include "base/file_util.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 user_.username_hash(), 62 user_.username_hash(),
63 base::Callback<void(crypto::ScopedPK11Slot)>()); 63 base::Callback<void(crypto::ScopedPK11Slot)>());
64 ASSERT_TRUE(private_slot_.get()); 64 ASSERT_TRUE(private_slot_.get());
65 test_nssdb_.reset(new net::NSSCertDatabaseChromeOS( 65 test_nssdb_.reset(new net::NSSCertDatabaseChromeOS(
66 crypto::GetPublicSlotForChromeOSUser(user_.username_hash()), 66 crypto::GetPublicSlotForChromeOSUser(user_.username_hash()),
67 crypto::GetPrivateSlotForChromeOSUser( 67 crypto::GetPrivateSlotForChromeOSUser(
68 user_.username_hash(), 68 user_.username_hash(),
69 base::Callback<void(crypto::ScopedPK11Slot)>()))); 69 base::Callback<void(crypto::ScopedPK11Slot)>())));
70 test_nssdb_->SetSlowTaskRunnerForTest(message_loop_.message_loop_proxy()); 70 test_nssdb_->SetSlowTaskRunnerForTest(message_loop_.message_loop_proxy());
71 71
72 DBusThreadManager::InitializeWithStub(); 72 DBusThreadManager::Initialize();
73 service_test_ = 73 service_test_ =
74 DBusThreadManager::Get()->GetShillServiceClient()->GetTestInterface(); 74 DBusThreadManager::Get()->GetShillServiceClient()->GetTestInterface();
75 profile_test_ = 75 profile_test_ =
76 DBusThreadManager::Get()->GetShillProfileClient()->GetTestInterface(); 76 DBusThreadManager::Get()->GetShillProfileClient()->GetTestInterface();
77 base::RunLoop().RunUntilIdle(); 77 base::RunLoop().RunUntilIdle();
78 service_test_->ClearServices(); 78 service_test_->ClearServices();
79 base::RunLoop().RunUntilIdle(); 79 base::RunLoop().RunUntilIdle();
80 80
81 TPMTokenLoader::InitializeForTest(); 81 TPMTokenLoader::InitializeForTest();
82 82
(...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after
309 base::RunLoop().RunUntilIdle(); 309 base::RunLoop().RunUntilIdle();
310 310
311 // Verify that the resolver positively matched the pattern in the policy with 311 // Verify that the resolver positively matched the pattern in the policy with
312 // the test client cert and configured the network. 312 // the test client cert and configured the network.
313 std::string pkcs11_id; 313 std::string pkcs11_id;
314 GetClientCertProperties(&pkcs11_id); 314 GetClientCertProperties(&pkcs11_id);
315 EXPECT_EQ(test_cert_id_, pkcs11_id); 315 EXPECT_EQ(test_cert_id_, pkcs11_id);
316 } 316 }
317 317
318 } // namespace chromeos 318 } // namespace chromeos
OLDNEW
« no previous file with comments | « chromeos/disks/disk_mount_manager_unittest.cc ('k') | chromeos/network/geolocation_handler_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698