OLD | NEW |
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 #include "base/basictypes.h" | 5 #include "base/basictypes.h" |
6 #include "chrome/browser/policy/mock_configuration_policy_provider.h" | 6 #include "chrome/browser/policy/mock_configuration_policy_provider.h" |
| 7 #include "chrome/browser/policy/policy_namespace.h" |
7 #include "chrome/browser/policy/proxy_policy_provider.h" | 8 #include "chrome/browser/policy/proxy_policy_provider.h" |
8 #include "testing/gmock/include/gmock/gmock.h" | 9 #include "testing/gmock/include/gmock/gmock.h" |
9 #include "testing/gtest/include/gtest/gtest.h" | 10 #include "testing/gtest/include/gtest/gtest.h" |
10 | 11 |
11 using testing::Mock; | 12 using testing::Mock; |
12 | 13 |
13 namespace policy { | 14 namespace policy { |
14 | 15 |
15 class ProxyPolicyProviderTest : public testing::Test { | 16 class ProxyPolicyProviderTest : public testing::Test { |
16 protected: | 17 protected: |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
87 proxy_provider_.RefreshPolicies(); | 88 proxy_provider_.RefreshPolicies(); |
88 Mock::VerifyAndClearExpectations(&observer_); | 89 Mock::VerifyAndClearExpectations(&observer_); |
89 Mock::VerifyAndClearExpectations(&mock_provider_); | 90 Mock::VerifyAndClearExpectations(&mock_provider_); |
90 | 91 |
91 EXPECT_CALL(observer_, OnUpdatePolicy(&proxy_provider_)); | 92 EXPECT_CALL(observer_, OnUpdatePolicy(&proxy_provider_)); |
92 mock_provider_.UpdatePolicy(scoped_ptr<PolicyBundle>(new PolicyBundle())); | 93 mock_provider_.UpdatePolicy(scoped_ptr<PolicyBundle>(new PolicyBundle())); |
93 Mock::VerifyAndClearExpectations(&observer_); | 94 Mock::VerifyAndClearExpectations(&observer_); |
94 } | 95 } |
95 | 96 |
96 } // namespace policy | 97 } // namespace policy |
OLD | NEW |