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 "base/bind.h" | 6 #include "base/bind.h" |
7 #include "base/message_loop.h" | 7 #include "base/message_loop.h" |
8 #include "base/synchronization/waitable_event.h" | 8 #include "base/synchronization/waitable_event.h" |
9 #include "remoting/host/dns_blackhole_checker.h" | 9 #include "remoting/host/dns_blackhole_checker.h" |
10 #include "remoting/host/policy_hack/fake_policy_watcher.h" | 10 #include "remoting/host/policy_hack/fake_policy_watcher.h" |
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
115 | 115 |
116 private: | 116 private: |
117 void SetDefaults(base::DictionaryValue& dict) { | 117 void SetDefaults(base::DictionaryValue& dict) { |
118 dict.SetBoolean(PolicyWatcher::kNatPolicyName, true); | 118 dict.SetBoolean(PolicyWatcher::kNatPolicyName, true); |
119 dict.SetBoolean(PolicyWatcher::kHostRequireTwoFactorPolicyName, false); | 119 dict.SetBoolean(PolicyWatcher::kHostRequireTwoFactorPolicyName, false); |
120 dict.SetString(PolicyWatcher::kHostDomainPolicyName, ""); | 120 dict.SetString(PolicyWatcher::kHostDomainPolicyName, ""); |
121 dict.SetBoolean(PolicyWatcher::kHostMatchUsernamePolicyName, false); | 121 dict.SetBoolean(PolicyWatcher::kHostMatchUsernamePolicyName, false); |
122 dict.SetString(PolicyWatcher::kHostTalkGadgetPrefixPolicyName, | 122 dict.SetString(PolicyWatcher::kHostTalkGadgetPrefixPolicyName, |
123 kDefaultHostTalkGadgetPrefix); | 123 kDefaultHostTalkGadgetPrefix); |
124 dict.SetBoolean(PolicyWatcher::kHostRequireCurtainPolicyName, false); | 124 dict.SetBoolean(PolicyWatcher::kHostRequireCurtainPolicyName, false); |
| 125 dict.SetString(PolicyWatcher::kHostTokenUrlPolicyName, ""); |
| 126 dict.SetString(PolicyWatcher::kHostTokenValidationUrlPolicyName, ""); |
125 #if !defined(NDEBUG) | 127 #if !defined(NDEBUG) |
126 dict.SetString(PolicyWatcher::kHostDebugOverridePoliciesName, ""); | 128 dict.SetString(PolicyWatcher::kHostDebugOverridePoliciesName, ""); |
127 #endif | 129 #endif |
128 } | 130 } |
129 }; | 131 }; |
130 | 132 |
131 const char* PolicyWatcherTest::kHostDomain = "google.com"; | 133 const char* PolicyWatcherTest::kHostDomain = "google.com"; |
132 | 134 |
133 MATCHER_P(IsPolicies, dict, "") { | 135 MATCHER_P(IsPolicies, dict, "") { |
134 return arg->Equals(dict); | 136 return arg->Equals(dict); |
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
297 OnPolicyUpdatePtr(IsPolicies(&nat_true_others_default_))); | 299 OnPolicyUpdatePtr(IsPolicies(&nat_true_others_default_))); |
298 #endif | 300 #endif |
299 | 301 |
300 StartWatching(); | 302 StartWatching(); |
301 policy_watcher_->SetPolicies(&nat_true_and_overridden_); | 303 policy_watcher_->SetPolicies(&nat_true_and_overridden_); |
302 StopWatching(); | 304 StopWatching(); |
303 } | 305 } |
304 | 306 |
305 } // namespace policy_hack | 307 } // namespace policy_hack |
306 } // namespace remoting | 308 } // namespace remoting |
OLD | NEW |