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

Unified Diff: chrome/browser/chromeos/login/mock_owner_key_utils.h

Issue 10824112: Move Chrome OS device settings stuff to chrome/browser/chromeos/settings. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase. Created 8 years, 5 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
« no previous file with comments | « chrome/browser/chromeos/login/login_utils.cc ('k') | chrome/browser/chromeos/login/mock_owner_key_utils.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/login/mock_owner_key_utils.h
diff --git a/chrome/browser/chromeos/login/mock_owner_key_utils.h b/chrome/browser/chromeos/login/mock_owner_key_utils.h
deleted file mode 100644
index 5bd0c452476df9ddfb97e44e74c2d2adfab144da..0000000000000000000000000000000000000000
--- a/chrome/browser/chromeos/login/mock_owner_key_utils.h
+++ /dev/null
@@ -1,61 +0,0 @@
-// Copyright (c) 2011 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.
-
-#ifndef CHROME_BROWSER_CHROMEOS_LOGIN_MOCK_OWNER_KEY_UTILS_H_
-#define CHROME_BROWSER_CHROMEOS_LOGIN_MOCK_OWNER_KEY_UTILS_H_
-
-#include <vector>
-
-#include "base/basictypes.h"
-#include "base/compiler_specific.h"
-#include "base/file_path.h"
-#include "crypto/rsa_private_key.h"
-#include "chrome/browser/chromeos/login/owner_key_utils.h"
-#include "testing/gmock/include/gmock/gmock.h"
-#include "testing/gtest/include/gtest/gtest.h"
-
-namespace chromeos {
-
-class MockKeyUtils : public OwnerKeyUtils {
- public:
- MockKeyUtils();
-
- MOCK_METHOD2(ImportPublicKey, bool(const FilePath& key_file,
- std::vector<uint8>* output));
- MOCK_METHOD3(Verify, bool(const std::string& data,
- const std::vector<uint8> signature,
- const std::vector<uint8> public_key));
- MOCK_METHOD3(Sign, bool(const std::string& data,
- std::vector<uint8>* OUT_signature,
- crypto::RSAPrivateKey* key));
- MOCK_METHOD1(FindPrivateKey,
- crypto::RSAPrivateKey*(const std::vector<uint8>& key));
- MOCK_METHOD0(GetOwnerKeyFilePath, FilePath());
- MOCK_METHOD2(ExportPublicKeyToFile, bool(crypto::RSAPrivateKey* pair,
- const FilePath& key_file));
- protected:
- virtual ~MockKeyUtils();
-
- private:
- DISALLOW_COPY_AND_ASSIGN(MockKeyUtils);
-};
-
-class MockInjector : public OwnerKeyUtils::Factory {
- public:
- // Takes ownership of |mock|.
- explicit MockInjector(MockKeyUtils* mock);
- virtual ~MockInjector();
-
- // If this is called, its caller takes ownership of |transient_|.
- // If it's never called, |transient_| remains our problem.
- virtual OwnerKeyUtils* CreateOwnerKeyUtils() OVERRIDE;
-
- private:
- scoped_refptr<MockKeyUtils> transient_;
- DISALLOW_COPY_AND_ASSIGN(MockInjector);
-};
-
-} // namespace chromeos
-
-#endif // CHROME_BROWSER_CHROMEOS_LOGIN_MOCK_OWNER_KEY_UTILS_H_
« no previous file with comments | « chrome/browser/chromeos/login/login_utils.cc ('k') | chrome/browser/chromeos/login/mock_owner_key_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698