OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "base/command_line.h" | 5 #include "base/command_line.h" |
6 #include "chrome/browser/media/webrtc_browsertest_base.h" | 6 #include "chrome/browser/media/webrtc_browsertest_base.h" |
7 #include "chrome/browser/media/webrtc_browsertest_common.h" | 7 #include "chrome/browser/media/webrtc_browsertest_common.h" |
8 #include "chrome/browser/ui/browser.h" | 8 #include "chrome/browser/ui/browser.h" |
9 #include "chrome/browser/ui/browser_tabstrip.h" | 9 #include "chrome/browser/ui/browser_tabstrip.h" |
10 #include "chrome/browser/ui/tabs/tab_strip_model.h" | 10 #include "chrome/browser/ui/tabs/tab_strip_model.h" |
11 #include "chrome/common/chrome_switches.h" | 11 #include "chrome/common/chrome_switches.h" |
12 #include "chrome/test/base/in_process_browser_test.h" | 12 #include "chrome/test/base/in_process_browser_test.h" |
13 #include "chrome/test/base/ui_test_utils.h" | 13 #include "chrome/test/base/ui_test_utils.h" |
14 #include "content/public/test/browser_test_utils.h" | 14 #include "content/public/test/browser_test_utils.h" |
| 15 #include "media/base/media_switches.h" |
15 #include "net/test/embedded_test_server/embedded_test_server.h" | 16 #include "net/test/embedded_test_server/embedded_test_server.h" |
16 | 17 |
17 static const char kMainWebrtcTestHtmlPage[] = | 18 static const char kMainWebrtcTestHtmlPage[] = |
18 "/webrtc/webrtc_jsep01_test.html"; | 19 "/webrtc/webrtc_jsep01_test.html"; |
19 | 20 |
20 // These tests runs on real webcams and ensure WebRTC can acquire webcams | 21 // These tests runs on real webcams and ensure WebRTC can acquire webcams |
21 // correctly. They will do nothing if there are no webcams on the system. | 22 // correctly. They will do nothing if there are no webcams on the system. |
22 // The webcam on the system must support up to 1080p, or the test will fail. | 23 // The webcam on the system must support up to 1080p, or the test will fail. |
23 class WebRtcWebcamBrowserTest : public WebRtcTestBase { | 24 class WebRtcWebcamBrowserTest : public WebRtcTestBase { |
24 public: | 25 public: |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
62 GetUserMediaAndGetStreamSize(tab, kAudioVideoCallConstraintsVGA)); | 63 GetUserMediaAndGetStreamSize(tab, kAudioVideoCallConstraintsVGA)); |
63 EXPECT_EQ("320x240", | 64 EXPECT_EQ("320x240", |
64 GetUserMediaAndGetStreamSize(tab, kAudioVideoCallConstraintsQVGA)); | 65 GetUserMediaAndGetStreamSize(tab, kAudioVideoCallConstraintsQVGA)); |
65 EXPECT_EQ("640x360", | 66 EXPECT_EQ("640x360", |
66 GetUserMediaAndGetStreamSize(tab, kAudioVideoCallConstraints360p)); | 67 GetUserMediaAndGetStreamSize(tab, kAudioVideoCallConstraints360p)); |
67 EXPECT_EQ("1280x720", | 68 EXPECT_EQ("1280x720", |
68 GetUserMediaAndGetStreamSize(tab, kAudioVideoCallConstraints720p)); | 69 GetUserMediaAndGetStreamSize(tab, kAudioVideoCallConstraints720p)); |
69 EXPECT_EQ("1920x1080", | 70 EXPECT_EQ("1920x1080", |
70 GetUserMediaAndGetStreamSize(tab, kAudioVideoCallConstraints1080p)); | 71 GetUserMediaAndGetStreamSize(tab, kAudioVideoCallConstraints1080p)); |
71 } | 72 } |
OLD | NEW |