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

Unified Diff: chrome/common/extensions/api/networking_private/networking_private_crypto_unittest.cc

Issue 102993002: Implement Networking Private API VerifyAndEncryptCredentials method (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Sync to r254157 Created 6 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: chrome/common/extensions/api/networking_private/networking_private_crypto_unittest.cc
diff --git a/chrome/browser/extensions/api/networking_private/networking_private_crypto_unittest.cc b/chrome/common/extensions/api/networking_private/networking_private_crypto_unittest.cc
similarity index 97%
rename from chrome/browser/extensions/api/networking_private/networking_private_crypto_unittest.cc
rename to chrome/common/extensions/api/networking_private/networking_private_crypto_unittest.cc
index 486166fce3e8a5c130e6c96b0e3a975c51732b69..e460c2be1e62246444b4c6ea87f6dd1f5f375c40 100644
--- a/chrome/browser/extensions/api/networking_private/networking_private_crypto_unittest.cc
+++ b/chrome/common/extensions/api/networking_private/networking_private_crypto_unittest.cc
@@ -1,7 +1,7 @@
// Copyright 2013 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "chrome/browser/extensions/api/networking_private/networking_private_crypto.h"
+#include "chrome/common/extensions/api/networking_private/networking_private_crypto.h"
#include "base/base64.h"
#include "base/logging.h"
@@ -142,7 +142,6 @@ TEST_F(NetworkingPrivateCryptoTest, EncryptByteString) {
static const char kTestData[] = "disco boy";
static const char kEmptyData[] = "";
-
std::string public_key;
base::Base64Decode(kPublicKey, &public_key);
@@ -159,13 +158,10 @@ TEST_F(NetworkingPrivateCryptoTest, EncryptByteString) {
EXPECT_TRUE(crypto.EncryptByteString(public_key, plain, &encrypted_output));
// Checking graceful fail for too much data to encrypt.
- EXPECT_FALSE(
- crypto.EncryptByteString(public_key,
- std::string(500, 'x'),
- &encrypted_output));
+ EXPECT_FALSE(crypto.EncryptByteString(
+ public_key, std::string(500, 'x'), &encrypted_output));
// Checking graceful fail for a bad key format.
EXPECT_FALSE(
crypto.EncryptByteString(kBadKeyData, kTestData, &encrypted_output));
}
-

Powered by Google App Engine
This is Rietveld 408576698