| 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 <set> | 5 #include <set> |
| 6 #include <string> | 6 #include <string> |
| 7 | 7 |
| 8 #include "base/logging.h" | 8 #include "base/logging.h" |
| 9 #include "base/message_loop.h" | 9 #include "base/message_loop.h" |
| 10 #include "base/values.h" | 10 #include "base/values.h" |
| 11 #include "base/version.h" | 11 #include "base/version.h" |
| 12 #include "chrome/browser/extensions/external_policy_loader.h" | 12 #include "chrome/browser/extensions/external_policy_loader.h" |
| 13 #include "chrome/browser/extensions/external_provider_impl.h" | 13 #include "chrome/browser/extensions/external_provider_impl.h" |
| 14 #include "chrome/browser/extensions/external_provider_interface.h" | 14 #include "chrome/browser/extensions/external_provider_interface.h" |
| 15 #include "chrome/common/extensions/extension.h" | 15 #include "chrome/common/extensions/extension.h" |
| 16 #include "chrome/common/extensions/manifest.h" | 16 #include "chrome/common/extensions/manifest.h" |
| 17 #include "chrome/common/pref_names.h" | 17 #include "chrome/common/pref_names.h" |
| 18 #include "chrome/test/base/testing_pref_service.h" | 18 #include "chrome/test/base/testing_pref_service_syncable.h" |
| 19 #include "chrome/test/base/testing_profile.h" | 19 #include "chrome/test/base/testing_profile.h" |
| 20 #include "content/public/test/test_browser_thread.h" | 20 #include "content/public/test/test_browser_thread.h" |
| 21 #include "testing/gtest/include/gtest/gtest.h" | 21 #include "testing/gtest/include/gtest/gtest.h" |
| 22 | 22 |
| 23 using content::BrowserThread; | 23 using content::BrowserThread; |
| 24 | 24 |
| 25 namespace extensions { | 25 namespace extensions { |
| 26 | 26 |
| 27 class ExternalPolicyLoaderTest : public testing::Test { | 27 class ExternalPolicyLoaderTest : public testing::Test { |
| 28 public: | 28 public: |
| (...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 140 // Add invalid entries. | 140 // Add invalid entries. |
| 141 forced_extensions.SetString("invalid", "http://www.example.com/crx"); | 141 forced_extensions.SetString("invalid", "http://www.example.com/crx"); |
| 142 forced_extensions.SetString("dddddddddddddddddddddddddddddddd", ""); | 142 forced_extensions.SetString("dddddddddddddddddddddddddddddddd", ""); |
| 143 forced_extensions.SetString("invalid", "bad"); | 143 forced_extensions.SetString("invalid", "bad"); |
| 144 | 144 |
| 145 MockExternalPolicyProviderVisitor mv; | 145 MockExternalPolicyProviderVisitor mv; |
| 146 mv.Visit(forced_extensions, expected_extensions); | 146 mv.Visit(forced_extensions, expected_extensions); |
| 147 } | 147 } |
| 148 | 148 |
| 149 } // namespace extensions | 149 } // namespace extensions |
| OLD | NEW |