| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 COMPONENTS_POLICY_CORE_COMMON_POLICY_TEST_UTILS_H_ | 5 #ifndef COMPONENTS_POLICY_CORE_COMMON_POLICY_TEST_UTILS_H_ |
| 6 #define COMPONENTS_POLICY_CORE_COMMON_POLICY_TEST_UTILS_H_ | 6 #define COMPONENTS_POLICY_CORE_COMMON_POLICY_TEST_UTILS_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <ostream> | 9 #include <ostream> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 29 matching lines...) Expand all Loading... |
| 40 | 40 |
| 41 PolicyDetailsMapping map_; | 41 PolicyDetailsMapping map_; |
| 42 | 42 |
| 43 DISALLOW_COPY_AND_ASSIGN(PolicyDetailsMap); | 43 DISALLOW_COPY_AND_ASSIGN(PolicyDetailsMap); |
| 44 }; | 44 }; |
| 45 | 45 |
| 46 // Returns true if |service| is not serving any policies. Otherwise logs the | 46 // Returns true if |service| is not serving any policies. Otherwise logs the |
| 47 // current policies and returns false. | 47 // current policies and returns false. |
| 48 bool PolicyServiceIsEmpty(const PolicyService* service); | 48 bool PolicyServiceIsEmpty(const PolicyService* service); |
| 49 | 49 |
| 50 #if defined(OS_IOS) || defined(OS_MACOSX) |
| 51 |
| 52 // Converts a base::Value to the equivalent CFPropertyListRef. |
| 53 // The returned value is owned by the caller. |
| 54 CFPropertyListRef ValueToProperty(const base::Value* value); |
| 55 |
| 56 #endif |
| 57 |
| 50 } // namespace policy | 58 } // namespace policy |
| 51 | 59 |
| 52 std::ostream& operator<<(std::ostream& os, const policy::PolicyBundle& bundle); | 60 std::ostream& operator<<(std::ostream& os, const policy::PolicyBundle& bundle); |
| 53 std::ostream& operator<<(std::ostream& os, policy::PolicyScope scope); | 61 std::ostream& operator<<(std::ostream& os, policy::PolicyScope scope); |
| 54 std::ostream& operator<<(std::ostream& os, policy::PolicyLevel level); | 62 std::ostream& operator<<(std::ostream& os, policy::PolicyLevel level); |
| 55 std::ostream& operator<<(std::ostream& os, policy::PolicyDomain domain); | 63 std::ostream& operator<<(std::ostream& os, policy::PolicyDomain domain); |
| 56 std::ostream& operator<<(std::ostream& os, const policy::PolicyMap& policies); | 64 std::ostream& operator<<(std::ostream& os, const policy::PolicyMap& policies); |
| 57 std::ostream& operator<<(std::ostream& os, const policy::PolicyMap::Entry& e); | 65 std::ostream& operator<<(std::ostream& os, const policy::PolicyMap::Entry& e); |
| 58 std::ostream& operator<<(std::ostream& os, const policy::PolicyNamespace& ns); | 66 std::ostream& operator<<(std::ostream& os, const policy::PolicyNamespace& ns); |
| 59 | 67 |
| 60 #endif // COMPONENTS_POLICY_CORE_COMMON_POLICY_TEST_UTILS_H_ | 68 #endif // COMPONENTS_POLICY_CORE_COMMON_POLICY_TEST_UTILS_H_ |
| OLD | NEW |