Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 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 | |
| 3 # found in the LICENSE file. | |
| 4 from telemetry import test | |
| 5 from telemetry.page import page_set | |
| 6 from webgl_conformance import WebglConformanceValidator | |
| 7 from webgl_conformance import conformance_harness_script | |
| 8 from webgl_conformance import conformance_path | |
| 9 | |
| 10 | |
| 11 robustness_harness_script = conformance_harness_script + r""" | |
| 12 window.confirm = function() { | |
| 13 var canvas = document.getElementById('example'); | |
| 14 canvas.addEventListener('webglcontextlost', function() { | |
| 15 webglTestHarness.notifyFinished(); | |
|
Ken Russell (switch to Gerrit)
2013/07/30 19:39:27
If the GPU happens to be fast enough to run that t
bajones
2013/07/30 20:51:03
Yeah, I worry that this is a race condition as wel
| |
| 16 }); | |
| 17 return true; | |
| 18 } | |
| 19 """ | |
| 20 | |
| 21 | |
| 22 class WebglRobustness(test.Test): | |
| 23 enabled = False | |
| 24 test = WebglConformanceValidator | |
| 25 | |
| 26 def CreatePageSet(self, options): | |
| 27 page_set_dict = { | |
| 28 'description': 'Test cases for WebGL robustness', | |
|
Ken Russell (switch to Gerrit)
2013/07/30 19:39:27
Just checking: this test won't be run by default,
| |
| 29 'user_agent_type': 'desktop', | |
| 30 'serving_dirs': [''], | |
| 31 'pages': [ | |
| 32 { | |
| 33 'url': 'file:///extra/lots-of-polys-example.html', | |
|
bajones
2013/07/30 20:51:03
Perhaps I'm missing something, but I don't see whe
| |
| 34 'script_to_evaluate_on_commit': robustness_harness_script, | |
| 35 'wait_for_javascript_expression': 'webglTestHarness._finished' | |
| 36 } | |
| 37 ] | |
| 38 } | |
| 39 return page_set.PageSet.FromDict(page_set_dict, conformance_path) | |
| OLD | NEW |