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

Unified Diff: chrome/browser/plugin_finder_unittest.cc

Issue 10933044: Move chrome/browser/plugin_* to chrome/browser/plugins/ (Closed) Base URL: http://git.chromium.org/chromium/src.git@remove_plugin_group
Patch Set: . Created 8 years, 3 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
« no previous file with comments | « chrome/browser/plugin_finder.cc ('k') | chrome/browser/plugin_infobar_delegates.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/plugin_finder_unittest.cc
diff --git a/chrome/browser/plugin_finder_unittest.cc b/chrome/browser/plugin_finder_unittest.cc
deleted file mode 100644
index 8d3d46b8b1e09aeba75750d8db3c979102bf78fb..0000000000000000000000000000000000000000
--- a/chrome/browser/plugin_finder_unittest.cc
+++ /dev/null
@@ -1,59 +0,0 @@
-// Copyright (c) 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "chrome/browser/plugin_finder.h"
-
-#include "base/values.h"
-#include "chrome/browser/plugin_installer.h"
-#include "testing/gtest/include/gtest/gtest.h"
-#include "webkit/plugins/npapi/plugin_list.h"
-
-using base::DictionaryValue;
-using webkit::npapi::PluginGroup;
-using webkit::npapi::PluginList;
-
-TEST(PluginFinderTest, JsonSyntax) {
- scoped_ptr<DictionaryValue> plugin_list(PluginFinder::LoadPluginList());
- ASSERT_TRUE(plugin_list.get());
- for (DictionaryValue::Iterator plugin_it(*plugin_list);
- plugin_it.HasNext(); plugin_it.Advance()) {
- const DictionaryValue* plugin = NULL;
- ASSERT_TRUE(plugin_it.value().GetAsDictionary(&plugin));
- std::string dummy_str;
- bool dummy_bool;
- if (plugin->HasKey("lang"))
- EXPECT_TRUE(plugin->GetString("lang", &dummy_str));
- if (plugin->HasKey("url"))
- EXPECT_TRUE(plugin->GetString("url", &dummy_str));
- EXPECT_TRUE(plugin->GetString("name", &dummy_str));
- if (plugin->HasKey("help_url"))
- EXPECT_TRUE(plugin->GetString("help_url", &dummy_str));
- if (plugin->HasKey("displayurl"))
- EXPECT_TRUE(plugin->GetBoolean("displayurl", &dummy_bool));
- if (plugin->HasKey("requires_authorization"))
- EXPECT_TRUE(plugin->GetBoolean("requires_authorization", &dummy_bool));
- const ListValue* mime_types = NULL;
- ASSERT_TRUE(plugin->GetList("mime_types", &mime_types));
- for (ListValue::const_iterator mime_type_it = mime_types->begin();
- mime_type_it != mime_types->end(); ++mime_type_it) {
- EXPECT_TRUE((*mime_type_it)->GetAsString(&dummy_str));
- }
- const ListValue* versions = NULL;
- if (!plugin->GetList("versions", &versions))
- continue;
-
- for (ListValue::const_iterator it = versions->begin();
- it != versions->end(); ++it) {
- DictionaryValue* version_dict = NULL;
- ASSERT_TRUE((*it)->GetAsDictionary(&version_dict));
- EXPECT_TRUE(version_dict->GetString("version", &dummy_str));
- std::string status_str;
- EXPECT_TRUE(version_dict->GetString("status", &status_str));
- PluginInstaller::SecurityStatus status =
- PluginInstaller::SECURITY_STATUS_UP_TO_DATE;
- EXPECT_TRUE(PluginInstaller::ParseSecurityStatus(status_str, &status))
- << "Invalid security status \"" << status_str << "\"";
- }
- }
-}
« no previous file with comments | « chrome/browser/plugin_finder.cc ('k') | chrome/browser/plugin_infobar_delegates.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698