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

Side by Side Diff: test/functional/webrtc_test_base.py

Issue 12824011: Updated Chrome Test pages (Closed) Base URL: https://src.chromium.org/svn/trunk/src/chrome/test/data/webrtc/
Patch Set: Created 7 years, 8 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
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 import os 6 import os
7 import re 7 import re
8 import subprocess 8 import subprocess
9 9
10 import pyauto 10 import pyauto
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 'dismiss'. 43 'dismiss'.
44 request_video: Whether to request video. 44 request_video: Whether to request video.
45 request_audio: Whether to request audio. 45 request_audio: Whether to request audio.
46 46
47 Returns: 47 Returns:
48 A string as specified by the getUserMedia javascript function. 48 A string as specified by the getUserMedia javascript function.
49 """ 49 """
50 constraints = '{ video: %s, audio: %s }' % (str(request_video).lower(), 50 constraints = '{ video: %s, audio: %s }' % (str(request_video).lower(),
51 str(request_audio).lower()) 51 str(request_audio).lower())
52 self.assertEquals('ok-requested', self.ExecuteJavascript( 52 self.assertEquals('ok-requested', self.ExecuteJavascript(
53 'getUserMedia("%s")' % constraints, tab_index=tab_index)) 53 'doGetUserMedia("%s")' % constraints, tab_index=tab_index))
54 54
55 self.WaitForInfobarCount(1, tab_index=tab_index) 55 self.WaitForInfobarCount(1, tab_index=tab_index)
56 self.PerformActionOnInfobar(action, infobar_index=0, tab_index=tab_index) 56 self.PerformActionOnInfobar(action, infobar_index=0, tab_index=tab_index)
57 self.WaitForGetUserMediaResult(tab_index=0) 57 self.WaitForGetUserMediaResult(tab_index=0)
58 58
59 result = self.GetUserMediaResult(tab_index=0) 59 result = self.GetUserMediaResult(tab_index=0)
60 self.AssertNoFailures(tab_index) 60 self.AssertNoFailures(tab_index)
61 return result 61 return result
62 62
63 def WaitForGetUserMediaResult(self, tab_index): 63 def WaitForGetUserMediaResult(self, tab_index):
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
197 'Could not locate peerconnection_server. Have you built the ' 197 'Could not locate peerconnection_server. Have you built the '
198 'peerconnection_server target? We expect to have a ' 198 'peerconnection_server target? We expect to have a '
199 'peerconnection_server binary next to the chrome binary.') 199 'peerconnection_server binary next to the chrome binary.')
200 200
201 self._server_process = subprocess.Popen(binary_path) 201 self._server_process = subprocess.Popen(binary_path)
202 202
203 def StopPeerConnectionServer(self): 203 def StopPeerConnectionServer(self):
204 """Stops the peerconnection_server.""" 204 """Stops the peerconnection_server."""
205 assert self._server_process 205 assert self._server_process
206 self._server_process.kill() 206 self._server_process.kill()
OLDNEW
« test/data/webrtc/manual/constraints.js ('K') | « test/functional/webrtc_brutality_test.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698