| OLD | NEW |
| 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2012 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 import os | 5 import os |
| 6 | 6 |
| 7 from telemetry.core import browser_credentials | 7 from telemetry.core import browser_credentials |
| 8 from telemetry.core import exceptions | 8 from telemetry.core import exceptions |
| 9 from telemetry.core import extension_dict | 9 from telemetry.core import extension_dict |
| 10 from telemetry.core import platform | 10 from telemetry.core import platform |
| (...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 252 output_files.extend(profiler.CollectProfile()) | 252 output_files.extend(profiler.CollectProfile()) |
| 253 self._active_profilers = [] | 253 self._active_profilers = [] |
| 254 return output_files | 254 return output_files |
| 255 | 255 |
| 256 def StartTracing(self, custom_categories=None, timeout=10): | 256 def StartTracing(self, custom_categories=None, timeout=10): |
| 257 return self._browser_backend.StartTracing(custom_categories, timeout) | 257 return self._browser_backend.StartTracing(custom_categories, timeout) |
| 258 | 258 |
| 259 def StopTracing(self): | 259 def StopTracing(self): |
| 260 return self._browser_backend.StopTracing() | 260 return self._browser_backend.StopTracing() |
| 261 | 261 |
| 262 @property |
| 263 def supports_synthetic_delays(self): |
| 264 return self._browser_backend.supports_synthetic_delays |
| 265 |
| 266 def ConfigureSyntheticDelays(self, delays, timeout=10): |
| 267 return self._browser_backend.ConfigureSyntheticDelays(delays, timeout) |
| 268 |
| 262 def Start(self): | 269 def Start(self): |
| 263 browser_options = self._browser_backend.browser_options | 270 browser_options = self._browser_backend.browser_options |
| 264 if browser_options.clear_sytem_cache_for_browser_and_profile_on_start: | 271 if browser_options.clear_sytem_cache_for_browser_and_profile_on_start: |
| 265 if self._platform.CanFlushIndividualFilesFromSystemCache(): | 272 if self._platform.CanFlushIndividualFilesFromSystemCache(): |
| 266 self._platform.FlushSystemCacheForDirectory( | 273 self._platform.FlushSystemCacheForDirectory( |
| 267 self._browser_backend.profile_directory) | 274 self._browser_backend.profile_directory) |
| 268 self._platform.FlushSystemCacheForDirectory( | 275 self._platform.FlushSystemCacheForDirectory( |
| 269 self._browser_backend.browser_directory) | 276 self._browser_backend.browser_directory) |
| 270 else: | 277 else: |
| 271 self._platform.FlushEntireSystemCache() | 278 self._platform.FlushEntireSystemCache() |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 358 | 365 |
| 359 @property | 366 @property |
| 360 def supports_system_info(self): | 367 def supports_system_info(self): |
| 361 return self._browser_backend.supports_system_info | 368 return self._browser_backend.supports_system_info |
| 362 | 369 |
| 363 def GetSystemInfo(self): | 370 def GetSystemInfo(self): |
| 364 """Returns low-level information about the system, if available. | 371 """Returns low-level information about the system, if available. |
| 365 | 372 |
| 366 See the documentation of the SystemInfo class for more details.""" | 373 See the documentation of the SystemInfo class for more details.""" |
| 367 return self._browser_backend.GetSystemInfo() | 374 return self._browser_backend.GetSystemInfo() |
| OLD | NEW |