| 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 from telemetry import story | 5 from telemetry import story |
| 6 from telemetry.page import page as page_module | 6 from telemetry.page import page as page_module |
| 7 | 7 |
| 8 | 8 |
| 9 class WebrtcPage(page_module.Page): | 9 class WebrtcPage(page_module.Page): |
| 10 | 10 |
| (...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 103 | 103 |
| 104 def __init__(self, page_set, tags): | 104 def __init__(self, page_set, tags): |
| 105 super(MultiplePeerConnections, self).__init__( | 105 super(MultiplePeerConnections, self).__init__( |
| 106 url='file://webrtc_cases/multiple-peerconnections.html', | 106 url='file://webrtc_cases/multiple-peerconnections.html', |
| 107 name='multiple_peerconnections', | 107 name='multiple_peerconnections', |
| 108 page_set=page_set, tags=tags) | 108 page_set=page_set, tags=tags) |
| 109 | 109 |
| 110 def RunPageInteractions(self, action_runner): | 110 def RunPageInteractions(self, action_runner): |
| 111 with action_runner.CreateInteraction('Action_Create_PeerConnection', | 111 with action_runner.CreateInteraction('Action_Create_PeerConnection', |
| 112 repeatable=False): | 112 repeatable=False): |
| 113 # Set the number of peer connections to create to 15. | 113 # Set the number of peer connections to create to 10. |
| 114 action_runner.ExecuteJavaScript( | 114 action_runner.ExecuteJavaScript( |
| 115 'document.getElementById("num-peerconnections").value=15') | 115 'document.getElementById("num-peerconnections").value=10') |
| 116 action_runner.ExecuteJavaScript( | 116 action_runner.ExecuteJavaScript( |
| 117 'document.getElementById("cpuoveruse-detection").checked=false') | 117 'document.getElementById("cpuoveruse-detection").checked=false') |
| 118 action_runner.ClickElement('button[id="start-test"]') | 118 action_runner.ClickElement('button[id="start-test"]') |
| 119 action_runner.Wait(45) | 119 action_runner.Wait(20) |
| 120 | 120 |
| 121 | 121 |
| 122 class WebrtcPageSet(story.StorySet): | 122 class WebrtcPageSet(story.StorySet): |
| 123 def __init__(self): | 123 def __init__(self): |
| 124 super(WebrtcPageSet, self).__init__( | 124 super(WebrtcPageSet, self).__init__( |
| 125 cloud_storage_bucket=story.PUBLIC_BUCKET) | 125 cloud_storage_bucket=story.PUBLIC_BUCKET) |
| 126 | 126 |
| 127 self.AddStory(MultiplePeerConnections(self, tags=['stress'])) |
| 128 self.AddStory(DataChannel(self, tags=['datachannel'])) |
| 127 self.AddStory(GetUserMedia(self, tags=['getusermedia'])) | 129 self.AddStory(GetUserMedia(self, tags=['getusermedia'])) |
| 128 self.AddStory(MultiplePeerConnections(self, tags=['stress'])) | |
| 129 self.AddStory(VideoCall(self, tags=['peerconnection', 'smoothness'])) | 130 self.AddStory(VideoCall(self, tags=['peerconnection', 'smoothness'])) |
| 130 self.AddStory(DataChannel(self, tags=['datachannel'])) | |
| 131 self.AddStory(CanvasCapturePeerConnection(self, tags=['smoothness'])) | 131 self.AddStory(CanvasCapturePeerConnection(self, tags=['smoothness'])) |
| 132 # TODO(qyearsley, mcasas): Add webrtc.audio when http://crbug.com/468732 | 132 self.AddStory(AudioCall(self, 'OPUS', tags=['audio'])) |
| 133 # is fixed, or revert https://codereview.chromium.org/1544573002/ when | 133 self.AddStory(AudioCall(self, 'G772', tags=['audio'])) |
| 134 # http://crbug.com/568333 is fixed. | 134 self.AddStory(AudioCall(self, 'PCMU', tags=['audio'])) |
| 135 # self.AddStory(AudioCall(self, 'OPUS')) | 135 self.AddStory(AudioCall(self, 'ISAC/1600', tags=['audio'])) |
| 136 # self.AddStory(AudioCall(self, 'G772')) | |
| 137 # self.AddStory(AudioCall(self, 'PCMU')) | |
| 138 # self.AddStory(AudioCall(self, 'ISAC/1600')) | |
| 139 | 136 |
| 140 | 137 |
| 141 class WebrtcExpectations(story.expectations.StoryExpectations): | 138 class WebrtcExpectations(story.expectations.StoryExpectations): |
| 142 def SetExpectations(self): | 139 def SetExpectations(self): |
| 143 self.DisableStory('multiple_peerconnections', | 140 # TODO(qyearsley, mcasas): Add webrtc.audio when http://crbug.com/468732 |
| 141 # is fixed, or revert https://codereview.chromium.org/1544573002/ when |
| 142 # http://crbug.com/568333 is fixed. |
| 143 self.DisableStory('audio_call_opus_10s', |
| 144 [story.expectations.ALL], | 144 [story.expectations.ALL], |
| 145 'crbug.com/725502') | 145 'crbug.com/468732') |
| 146 self.DisableStory('audio_call_g772_10s', |
| 147 [story.expectations.ALL], |
| 148 'crbug.com/468732') |
| 149 self.DisableStory('audio_call_pcmu_10s', |
| 150 [story.expectations.ALL], |
| 151 'crbug.com/468732') |
| 152 self.DisableStory('audio_call_isac/1600_10s', |
| 153 [story.expectations.ALL], |
| 154 'crbug.com/468732') |
| 155 |
| 146 self.DisableStory('30s_datachannel_transfer', | 156 self.DisableStory('30s_datachannel_transfer', |
| 147 [story.expectations.ALL_DESKTOP], | 157 [story.expectations.ALL_DESKTOP], |
| 148 'crbug.com/726811') | 158 'crbug.com/726811') |
| OLD | NEW |