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

Side by Side Diff: content/browser/media/webrtc_aecdump_browsertest.cc

Issue 190563002: Refactored how WebRTC content browser tests talk to their javascript. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed AEC dump tests on Andri Created 6 years, 9 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | content/browser/media/webrtc_browsertest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 "base/file_util.h" 6 #include "base/file_util.h"
7 #include "base/json/json_reader.h" 7 #include "base/json/json_reader.h"
8 #include "base/platform_file.h" 8 #include "base/platform_file.h"
9 #include "base/strings/stringprintf.h" 9 #include "base/strings/stringprintf.h"
10 #include "base/strings/utf_string_conversions.h" 10 #include "base/strings/utf_string_conversions.h"
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 // This tests will make a complete PeerConnection-based call, verify that 60 // This tests will make a complete PeerConnection-based call, verify that
61 // video is playing for the call, and verify that a non-empty AEC dump file 61 // video is playing for the call, and verify that a non-empty AEC dump file
62 // exists. 62 // exists.
63 IN_PROC_BROWSER_TEST_F(WebRtcAecDumpBrowserTest, MAYBE_CallWithAecDump) { 63 IN_PROC_BROWSER_TEST_F(WebRtcAecDumpBrowserTest, MAYBE_CallWithAecDump) {
64 ASSERT_TRUE(embedded_test_server()->InitializeAndWaitUntilReady()); 64 ASSERT_TRUE(embedded_test_server()->InitializeAndWaitUntilReady());
65 65
66 GURL url(embedded_test_server()->GetURL("/media/peerconnection-call.html")); 66 GURL url(embedded_test_server()->GetURL("/media/peerconnection-call.html"));
67 NavigateToURL(shell(), url); 67 NavigateToURL(shell(), url);
68 68
69 #if defined (OS_ANDROID) 69 #if defined (OS_ANDROID)
70 // Always force iSAC 16K on Android for now (Opus is broken). 70 // Always force iSAC 16K on Android for now (Opus is broken).
71 ASSERT_TRUE(ExecuteJavascript("forceIsac16KInSdp();")); 71 EXPECT_EQ("isac-forced",
72 ExecuteJavascriptAndReturnResult("forceIsac16KInSdp();"));
72 #endif 73 #endif
73 74
74 EXPECT_TRUE(ExecuteJavascript("call({video: true, audio: true});")); 75 ExecuteJavascriptAndWaitForOk("call({video: true, audio: true});");
75 ExpectTitle("OK");
76 76
77 EXPECT_TRUE(base::PathExists(dump_file_)); 77 EXPECT_TRUE(base::PathExists(dump_file_));
78 int64 file_size = 0; 78 int64 file_size = 0;
79 EXPECT_TRUE(base::GetFileSize(dump_file_, &file_size)); 79 EXPECT_TRUE(base::GetFileSize(dump_file_, &file_size));
80 EXPECT_GT(file_size, 0); 80 EXPECT_GT(file_size, 0);
81 } 81 }
82 82
83 } // namespace content 83 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/browser/media/webrtc_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698