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

Unified Diff: chrome/browser/policy/mock_cloud_policy_store.h

Issue 10092010: Add CloudPolicyService (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address comments. Created 8 years, 7 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/browser/policy/mock_cloud_policy_store.h
diff --git a/chrome/browser/policy/mock_cloud_policy_store.h b/chrome/browser/policy/mock_cloud_policy_store.h
new file mode 100644
index 0000000000000000000000000000000000000000..4e1e62a1f13aea6d5c7e55df6617ed93b80520e3
--- /dev/null
+++ b/chrome/browser/policy/mock_cloud_policy_store.h
@@ -0,0 +1,32 @@
+// Copyright (c) 2012 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_POLICY_MOCK_CLOUD_POLICY_STORE_H_
+#define CHROME_BROWSER_POLICY_MOCK_CLOUD_POLICY_STORE_H_
+#pragma once
+
+#include "chrome/browser/policy/cloud_policy_store.h"
+#include "testing/gmock/include/gmock/gmock.h"
+
+namespace policy {
+
+class MockCloudPolicyStore : public CloudPolicyStore {
+ public:
+ MockCloudPolicyStore() {}
Joao da Silva 2012/05/22 22:01:44 Clang says this complex ctor must be out-of-line,
Mattias Nissler (ping if slow) 2012/05/24 10:12:25 Done.
+
+ MOCK_METHOD1(Store, void(const enterprise_management::PolicyFetchResponse&));
+ MOCK_METHOD0(Load, void(void));
+
+ // Publish the protected members.
+ using CloudPolicyStore::NotifyStoreLoaded;
+ using CloudPolicyStore::NotifyStoreError;
+
+ using CloudPolicyStore::policy_map_;
+ using CloudPolicyStore::policy_;
+ using CloudPolicyStore::status_;
+};
+
+} // namespace policy
+
+#endif // CHROME_BROWSER_POLICY_MOCK_CLOUD_POLICY_STORE_H_

Powered by Google App Engine
This is Rietveld 408576698