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 import json | 4 import json |
5 import os | 5 import os |
6 import sys | 6 import sys |
7 | 7 |
8 import webgl_conformance_expectations | 8 import webgl_conformance_expectations |
9 | 9 |
10 from telemetry import test as test_module | 10 from telemetry import test as test_module |
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
77 'serving_dirs': [ '' ], | 77 'serving_dirs': [ '' ], |
78 'pages': [] | 78 'pages': [] |
79 } | 79 } |
80 | 80 |
81 pages = page_set_dict['pages'] | 81 pages = page_set_dict['pages'] |
82 | 82 |
83 for test in tests: | 83 for test in tests: |
84 pages.append({ | 84 pages.append({ |
85 'url': 'file:///' + test, | 85 'url': 'file:///' + test, |
86 'script_to_evaluate_on_commit': conformance_harness_script, | 86 'script_to_evaluate_on_commit': conformance_harness_script, |
87 'wait_for_javascript_expression': 'webglTestHarness._finished' | 87 'navigate_steps': [ |
| 88 { 'action': 'navigate' }, |
| 89 { |
| 90 'action': 'wait', |
| 91 'condition': 'javascript', |
| 92 'javascript': 'webglTestHarness._finished' |
| 93 } |
| 94 ] |
88 }) | 95 }) |
89 | 96 |
90 return page_set.PageSet.FromDict(page_set_dict, conformance_path) | 97 return page_set.PageSet.FromDict(page_set_dict, conformance_path) |
91 | 98 |
92 def CreateExpectations(self, page_set): | 99 def CreateExpectations(self, page_set): |
93 return webgl_conformance_expectations.WebGLConformanceExpectations() | 100 return webgl_conformance_expectations.WebGLConformanceExpectations() |
94 | 101 |
95 @staticmethod | 102 @staticmethod |
96 def _ParseTests(path, version=None): | 103 def _ParseTests(path, version=None): |
97 test_paths = [] | 104 test_paths = [] |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
130 | 137 |
131 if '.txt' in test_name: | 138 if '.txt' in test_name: |
132 include_path = os.path.join(current_dir, test_name) | 139 include_path = os.path.join(current_dir, test_name) |
133 test_paths += WebglConformance._ParseTests( | 140 test_paths += WebglConformance._ParseTests( |
134 include_path, version) | 141 include_path, version) |
135 else: | 142 else: |
136 test = os.path.join(current_dir, test_name) | 143 test = os.path.join(current_dir, test_name) |
137 test_paths.append(test) | 144 test_paths.append(test) |
138 | 145 |
139 return test_paths | 146 return test_paths |
OLD | NEW |