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

Unified Diff: content/renderer/browser_plugin/browser_plugin_browsertest.cc

Issue 10917225: Browser Plugin: Reload and Stop operations (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed nit 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 | « content/renderer/browser_plugin/browser_plugin_bindings.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/browser_plugin/browser_plugin_browsertest.cc
diff --git a/content/renderer/browser_plugin/browser_plugin_browsertest.cc b/content/renderer/browser_plugin/browser_plugin_browsertest.cc
index 6d23e0cade9a60e29e69858877d2a91a49377dde..a986f6bb197579147ea60b77974ce630c59b472e 100644
--- a/content/renderer/browser_plugin/browser_plugin_browsertest.cc
+++ b/content/renderer/browser_plugin/browser_plugin_browsertest.cc
@@ -323,4 +323,22 @@ TEST_F(BrowserPluginTest, CustomEvents) {
EXPECT_EQ(kGoogleURL, ExecuteScriptAndReturnString("url"));
}
+TEST_F(BrowserPluginTest, StopMethod) {
+ const char* kCallStop =
+ "document.getElementById('browserplugin').stop();";
+ LoadHTML(GetHTMLForBrowserPluginObject().c_str());
+ ExecuteJavaScript(kCallStop);
+ EXPECT_TRUE(browser_plugin_manager()->sink().GetUniqueMessageMatching(
+ BrowserPluginHostMsg_Stop::ID));
+}
+
+TEST_F(BrowserPluginTest, ReloadMethod) {
+ const char* kCallReload =
+ "document.getElementById('browserplugin').reload();";
+ LoadHTML(GetHTMLForBrowserPluginObject().c_str());
+ ExecuteJavaScript(kCallReload);
+ EXPECT_TRUE(browser_plugin_manager()->sink().GetUniqueMessageMatching(
+ BrowserPluginHostMsg_Reload::ID));
+}
+
} // namespace content
« no previous file with comments | « content/renderer/browser_plugin/browser_plugin_bindings.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698