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

Side by Side Diff: chrome/browser/policy/mock_policy_service.h

Issue 15061007: Added a PolicyDomainDescriptor. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 4
5 #ifndef CHROME_BROWSER_POLICY_MOCK_POLICY_SERVICE_H_ 5 #ifndef CHROME_BROWSER_POLICY_MOCK_POLICY_SERVICE_H_
6 #define CHROME_BROWSER_POLICY_MOCK_POLICY_SERVICE_H_ 6 #define CHROME_BROWSER_POLICY_MOCK_POLICY_SERVICE_H_
7 7
8 #include "chrome/browser/policy/policy_domain_descriptor.h"
8 #include "chrome/browser/policy/policy_service.h" 9 #include "chrome/browser/policy/policy_service.h"
9 #include "testing/gmock/include/gmock/gmock.h" 10 #include "testing/gmock/include/gmock/gmock.h"
10 11
11 namespace policy { 12 namespace policy {
12 13
13 class MockPolicyService : public PolicyService { 14 class MockPolicyService : public PolicyService {
14 public: 15 public:
15 MockPolicyService(); 16 MockPolicyService();
16 ~MockPolicyService(); 17 ~MockPolicyService();
17 18
18 MOCK_METHOD2(AddObserver, void(PolicyDomain, Observer*)); 19 MOCK_METHOD2(AddObserver, void(PolicyDomain, Observer*));
19 MOCK_METHOD2(RemoveObserver, void(PolicyDomain, Observer*)); 20 MOCK_METHOD2(RemoveObserver, void(PolicyDomain, Observer*));
20 21
21 MOCK_METHOD2(RegisterPolicyDomain, void(PolicyDomain, 22 MOCK_METHOD1(RegisterPolicyDomain,
22 const std::set<std::string>&)); 23 void(scoped_refptr<const PolicyDomainDescriptor>));
23 24
24 MOCK_CONST_METHOD1(GetPolicies, const PolicyMap&(const PolicyNamespace&)); 25 MOCK_CONST_METHOD1(GetPolicies, const PolicyMap&(const PolicyNamespace&));
25 MOCK_CONST_METHOD1(IsInitializationComplete, bool(PolicyDomain domain)); 26 MOCK_CONST_METHOD1(IsInitializationComplete, bool(PolicyDomain domain));
26 MOCK_METHOD1(RefreshPolicies, void(const base::Closure&)); 27 MOCK_METHOD1(RefreshPolicies, void(const base::Closure&));
27 }; 28 };
28 29
29 } // namespace policy 30 } // namespace policy
30 31
31 #endif // CHROME_BROWSER_POLICY_MOCK_POLICY_SERVICE_H_ 32 #endif // CHROME_BROWSER_POLICY_MOCK_POLICY_SERVICE_H_
OLDNEW
« no previous file with comments | « chrome/browser/policy/mock_configuration_policy_provider.h ('k') | chrome/browser/policy/policy_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698