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

Unified Diff: content/browser/webrtc/webrtc_webcam_browsertest.cc

Issue 2341643006: ImageCapture browser tests: use IsWebcamAvailableOnSystem() (Closed)
Patch Set: 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/browser/webrtc/webrtc_webcam_browsertest.cc
diff --git a/content/browser/webrtc/webrtc_webcam_browsertest.cc b/content/browser/webrtc/webrtc_webcam_browsertest.cc
index 223c5de56c2b91a7e67a08999451815d6b37fa68..95719df946430eb37333c09f111edf851409fc22 100644
--- a/content/browser/webrtc/webrtc_webcam_browsertest.cc
+++ b/content/browser/webrtc/webrtc_webcam_browsertest.cc
@@ -66,6 +66,7 @@ void WebRtcWebcamBrowserTest::SetUp() {
// only want it to run on bots where we can ensure sequential execution. The
// Android bots will run the test since they ignore MANUAL, but that's what we
// want here since the bot runs tests sequentially on the device.
+// Tests that GetUserMedia acquire VGA by default.
IN_PROC_BROWSER_TEST_F(WebRtcWebcamBrowserTest,
MANUAL_CanAcquireVgaOnRealWebcam) {
ASSERT_TRUE(embedded_test_server()->Start());
@@ -73,13 +74,12 @@ IN_PROC_BROWSER_TEST_F(WebRtcWebcamBrowserTest,
"/media/getusermedia-real-webcam.html"));
NavigateToURL(shell(), url);
- std::string result;
if (!IsWebcamAvailableOnSystem(shell()->web_contents())) {
DVLOG(0) << "No video device; skipping test...";
return;
}
- // GetUserMedia should acquire VGA by default.
+ std::string result;
ASSERT_TRUE(ExecuteScriptAndExtractString(
shell(), "getUserMediaAndReturnVideoDimensions({video: true})", &result));
@@ -88,7 +88,7 @@ IN_PROC_BROWSER_TEST_F(WebRtcWebcamBrowserTest,
// since we don't know how it is oriented in the lab :)
return;
}
- FAIL() << "Expected resolution to be 640x480 or 480x640, got" << result;
+ FAIL() << "Expected resolution to be 640x480 or 480x640, got: " << result;
}
} // namespace content

Powered by Google App Engine
This is Rietveld 408576698