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

Unified Diff: content/public/test/browser_test_utils.cc

Issue 2310683003: Removed duplicated JS hasVideoInputDeviceOnSystem() test helper (Closed)
Patch Set: Initial commit Created 4 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
Index: content/public/test/browser_test_utils.cc
diff --git a/content/public/test/browser_test_utils.cc b/content/public/test/browser_test_utils.cc
index 802d4eba324aefe2afe3628832346c879ff54346..f18393ec0ae765514821f5759a102a070146c327 100644
--- a/content/public/test/browser_test_utils.cc
+++ b/content/public/test/browser_test_utils.cc
@@ -742,6 +742,13 @@ void SimulateKeyPress(WebContents* web_contents,
ASSERT_EQ(modifiers, 0);
}
+bool HasWebcamAvailableOnSystem(WebContents* tab_contents) {
+ std::string result;
+ EXPECT_TRUE(content::ExecuteScriptAndExtractString(
+ tab_contents, hasVideoInputDeviceOnSystem, &result));
+ return result == "has-video-input-device";
+}
+
RenderFrameHost* ConvertToRenderFrameHost(WebContents* web_contents) {
return web_contents->GetMainFrame();
}

Powered by Google App Engine
This is Rietveld 408576698