| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/utf_string_conversions.h" | 5 #include "base/utf_string_conversions.h" |
| 6 #include "chrome/browser/content_settings/host_content_settings_map.h" | 6 #include "chrome/browser/content_settings/host_content_settings_map.h" |
| 7 #include "chrome/browser/extensions/extension_apitest.h" | 7 #include "chrome/browser/extensions/extension_apitest.h" |
| 8 #include "chrome/browser/extensions/extension_content_settings_api.h" | 8 #include "chrome/browser/extensions/extension_content_settings_api.h" |
| 9 #include "chrome/browser/prefs/pref_service.h" | 9 #include "chrome/browser/prefs/pref_service.h" |
| 10 #include "chrome/browser/profiles/profile.h" | 10 #include "chrome/browser/profiles/profile.h" |
| (...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 110 plugin_list.AddPluginToLoad( | 110 plugin_list.AddPluginToLoad( |
| 111 webkit::WebPluginInfo(ASCIIToUTF16(kFooName), | 111 webkit::WebPluginInfo(ASCIIToUTF16(kFooName), |
| 112 FilePath(kFooPath), | 112 FilePath(kFooPath), |
| 113 ASCIIToUTF16("1.2.3"), | 113 ASCIIToUTF16("1.2.3"), |
| 114 ASCIIToUTF16("foo"))); | 114 ASCIIToUTF16("foo"))); |
| 115 plugin_list.AddPluginToLoad( | 115 plugin_list.AddPluginToLoad( |
| 116 webkit::WebPluginInfo(ASCIIToUTF16(kBarName), | 116 webkit::WebPluginInfo(ASCIIToUTF16(kBarName), |
| 117 FilePath(kBarPath), | 117 FilePath(kBarPath), |
| 118 ASCIIToUTF16("2.3.4"), | 118 ASCIIToUTF16("2.3.4"), |
| 119 ASCIIToUTF16("bar"))); | 119 ASCIIToUTF16("bar"))); |
| 120 GetResourceIdentifiersFunction::SetPluginListForTesting(&plugin_list); | 120 |
| 121 std::vector<webkit::npapi::PluginGroup> groups; |
| 122 plugin_list.GetPluginGroups(true, &groups); |
| 123 |
| 124 GetResourceIdentifiersFunction::SetPluginGroupsForTesting(&groups); |
| 121 | 125 |
| 122 EXPECT_TRUE(RunExtensionTest("content_settings/getresourceidentifiers")) | 126 EXPECT_TRUE(RunExtensionTest("content_settings/getresourceidentifiers")) |
| 123 << message_; | 127 << message_; |
| 124 | 128 |
| 125 GetResourceIdentifiersFunction::SetPluginListForTesting(NULL); | 129 GetResourceIdentifiersFunction::SetPluginGroupsForTesting(NULL); |
| 126 } | 130 } |
| OLD | NEW |