Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(273)

Unified Diff: webkit/plugins/npapi/plugin_group_unittest.cc

Issue 6350010: Put some plug-ins behind an infobar, where they have:... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webkit/plugins/npapi/plugin_group_unittest.cc
===================================================================
--- webkit/plugins/npapi/plugin_group_unittest.cc (revision 72707)
+++ webkit/plugins/npapi/plugin_group_unittest.cc (working copy)
@@ -20,17 +20,17 @@
namespace npapi {
static const VersionRangeDefinition kPluginVersionRange[] = {
- { "", "", "3.0.44" }
+ { "", "", "3.0.44", false }
};
static const VersionRangeDefinition kPlugin3VersionRange[] = {
- { "0", "4", "3.0.44" }
+ { "0", "4", "3.0.44", false }
};
static const VersionRangeDefinition kPlugin4VersionRange[] = {
- { "4", "5", "4.0.44" }
+ { "4", "5", "4.0.44", false }
};
static const VersionRangeDefinition kPlugin34VersionRange[] = {
- { "0", "4", "3.0.44" },
- { "4", "5", "" }
+ { "0", "4", "3.0.44", false },
+ { "4", "5", "", false }
};
static const PluginGroupDefinition kPluginDef = {
@@ -227,9 +227,9 @@
TEST(PluginGroupTest, IsVulnerable) {
// Adobe Reader 10
VersionRangeDefinition adobe_reader_version_range[] = {
- { "10", "11", "" },
- { "9", "10", "9.4.1" },
- { "0", "9", "8.2.5" }
+ { "10", "11", "", false },
+ { "9", "10", "9.4.1", false },
+ { "0", "9", "8.2.5", false }
};
PluginGroupDefinition adobe_reader_plugin_def = {
"adobe-reader", "Adobe Reader", "Adobe Acrobat",
@@ -244,11 +244,12 @@
group->AddPlugin(adobe_reader_plugin);
PluginGroup group_copy(*group); // Exercise the copy constructor.
EXPECT_FALSE(group_copy.IsVulnerable());
+ EXPECT_FALSE(group_copy.RequiresAuthorization());
// Silverlight 4
VersionRangeDefinition silverlight_version_range[] = {
- { "0", "4", "3.0.50106.0" },
- { "4", "5", "" }
+ { "0", "4", "3.0.50106.0", false },
+ { "4", "5", "", true }
};
PluginGroupDefinition silverlight_plugin_def = {
"silverlight", "Silverlight", "Silverlight", silverlight_version_range,
@@ -261,6 +262,7 @@
group.reset(PluginGroupTest::CreatePluginGroup(silverlight_plugin_def));
group->AddPlugin(silverlight_plugin);
EXPECT_FALSE(PluginGroup(*group).IsVulnerable());
+ EXPECT_TRUE(PluginGroup(*group).RequiresAuthorization());
}
} // namespace npapi
} // namespace webkit

Powered by Google App Engine
This is Rietveld 408576698