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

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

Issue 19706002: Remove plugin_list.h includes from chrome tests in preparation for moving webkit/plugins to content… (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: fix posix tests Created 7 years, 5 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 | « webkit/plugins/npapi/plugin_list.h ('k') | webkit/plugins/webkit_plugins.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/plugins/npapi/plugin_list_unittest.cc
===================================================================
--- webkit/plugins/npapi/plugin_list_unittest.cc (revision 212185)
+++ webkit/plugins/npapi/plugin_list_unittest.cc (working copy)
@@ -7,7 +7,6 @@
#include "base/strings/string16.h"
#include "base/strings/utf_string_conversions.h"
#include "testing/gtest/include/gtest/gtest.h"
-#include "webkit/plugins/npapi/mock_plugin_list.h"
namespace webkit {
namespace npapi {
@@ -31,12 +30,15 @@
return false;
}
+} // namespace
+
+// Linux Aura doesn't support NPAPI.
+#if !(defined(OS_LINUX) && defined(USE_AURA))
+
base::FilePath::CharType kFooPath[] = FILE_PATH_LITERAL("/plugins/foo.plugin");
base::FilePath::CharType kBarPath[] = FILE_PATH_LITERAL("/plugins/bar.plugin");
const char* kFooName = "Foo Plugin";
-} // namespace
-
class PluginListTest : public testing::Test {
public:
PluginListTest()
@@ -51,12 +53,13 @@
}
virtual void SetUp() {
- plugin_list_.AddPluginToLoad(bar_plugin_);
- plugin_list_.AddPluginToLoad(foo_plugin_);
+ plugin_list_.DisablePluginsDiscovery();
+ plugin_list_.RegisterInternalPlugin(bar_plugin_, false);
+ plugin_list_.RegisterInternalPlugin(foo_plugin_, false);
}
protected:
- MockPluginList plugin_list_;
+ PluginList plugin_list_;
WebPluginInfo foo_plugin_;
WebPluginInfo bar_plugin_;
};
@@ -74,8 +77,7 @@
base::string16(), base::FilePath(FILE_PATH_LITERAL("/myplugin.3.0.43")),
base::string16(), base::string16());
// Simulate loading of the plugins.
- plugin_list_.ClearPluginsToLoad();
- plugin_list_.AddPluginToLoad(plugin_3043);
+ plugin_list_.RegisterInternalPlugin(plugin_3043, false);
// Now we should have them in the state we specified above.
plugin_list_.RefreshPlugins();
std::vector<WebPluginInfo> plugins;
@@ -83,6 +85,8 @@
ASSERT_TRUE(Contains(plugins, plugin_3043));
}
+#endif
+
#if defined(OS_POSIX) && !defined(OS_MACOSX)
// Test parsing a simple description: Real Audio.
« no previous file with comments | « webkit/plugins/npapi/plugin_list.h ('k') | webkit/plugins/webkit_plugins.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698