| Index: crypto/rsa_private_key_nss_unittest.cc
|
| ===================================================================
|
| --- crypto/rsa_private_key_nss_unittest.cc (revision 79901)
|
| +++ crypto/rsa_private_key_nss_unittest.cc (working copy)
|
| @@ -2,7 +2,7 @@
|
| // Use of this source code is governed by a BSD-style license that can be
|
| // found in the LICENSE file.
|
|
|
| -#include "base/crypto/rsa_private_key.h"
|
| +#include "crypto/rsa_private_key.h"
|
|
|
| #include <keyhi.h>
|
| #include <pk11pub.h>
|
| @@ -11,7 +11,7 @@
|
| #include "base/nss_util.h"
|
| #include "testing/gtest/include/gtest/gtest.h"
|
|
|
| -namespace base {
|
| +namespace crypto {
|
|
|
| class RSAPrivateKeyNSSTest : public testing::Test {
|
| public:
|
| @@ -20,7 +20,7 @@
|
|
|
| virtual void SetUp() {
|
| #if defined(OS_CHROMEOS)
|
| - base::OpenPersistentNSSDB();
|
| + OpenPersistentNSSDB();
|
| #endif
|
| }
|
|
|
| @@ -30,20 +30,20 @@
|
|
|
| TEST_F(RSAPrivateKeyNSSTest, FindFromPublicKey) {
|
| // Create a keypair, which will put the keys in the user's NSSDB.
|
| - scoped_ptr<base::RSAPrivateKey> key_pair(base::RSAPrivateKey::Create(256));
|
| + scoped_ptr<crypto::RSAPrivateKey> key_pair(RSAPrivateKey::Create(256));
|
|
|
| std::vector<uint8> public_key;
|
| ASSERT_TRUE(key_pair->ExportPublicKey(&public_key));
|
|
|
| - scoped_ptr<base::RSAPrivateKey> key_pair_2(
|
| - base::RSAPrivateKey::FindFromPublicKeyInfo(public_key));
|
| + scoped_ptr<crypto::RSAPrivateKey> key_pair_2(
|
| + crypto::RSAPrivateKey::FindFromPublicKeyInfo(public_key));
|
|
|
| EXPECT_EQ(key_pair->key_->pkcs11ID, key_pair_2->key_->pkcs11ID);
|
| }
|
|
|
| TEST_F(RSAPrivateKeyNSSTest, FailedFindFromPublicKey) {
|
| // Create a keypair, which will put the keys in the user's NSSDB.
|
| - scoped_ptr<base::RSAPrivateKey> key_pair(base::RSAPrivateKey::Create(256));
|
| + scoped_ptr<crypto::RSAPrivateKey> key_pair(RSAPrivateKey::Create(256));
|
|
|
| std::vector<uint8> public_key;
|
| ASSERT_TRUE(key_pair->ExportPublicKey(&public_key));
|
| @@ -58,7 +58,7 @@
|
| key_pair->public_key_->pkcs11ID);
|
| }
|
|
|
| - EXPECT_EQ(NULL, base::RSAPrivateKey::FindFromPublicKeyInfo(public_key));
|
| + EXPECT_EQ(NULL, crypto::RSAPrivateKey::FindFromPublicKeyInfo(public_key));
|
| }
|
|
|
| -} // namespace base
|
| +} // namespace crypto
|
|
|