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 optparse | 5 import optparse |
6 import os | 6 import os |
7 import sys | 7 import sys |
8 | 8 |
9 import webgl_conformance_expectations | 9 import webgl_conformance_expectations |
10 | 10 |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
101 def AddTestCommandLineArgs(cls, group): | 101 def AddTestCommandLineArgs(cls, group): |
102 group.add_option('--webgl-conformance-version', | 102 group.add_option('--webgl-conformance-version', |
103 help='Version of the WebGL conformance tests to run.', | 103 help='Version of the WebGL conformance tests to run.', |
104 default='1.0.3') | 104 default='1.0.3') |
105 | 105 |
106 def CreatePageSet(self, options): | 106 def CreatePageSet(self, options): |
107 tests = self._ParseTests('00_test_list.txt', | 107 tests = self._ParseTests('00_test_list.txt', |
108 options.webgl_conformance_version) | 108 options.webgl_conformance_version) |
109 | 109 |
110 ps = page_set.PageSet( | 110 ps = page_set.PageSet( |
111 description='Executes WebGL conformance tests', | |
112 user_agent_type='desktop', | 111 user_agent_type='desktop', |
113 serving_dirs=[''], | 112 serving_dirs=[''], |
114 file_path=conformance_path) | 113 file_path=conformance_path) |
115 | 114 |
116 for test in tests: | 115 for test in tests: |
117 ps.AddPage(WebglConformancePage(ps, test)) | 116 ps.AddPage(WebglConformancePage(ps, test)) |
118 | 117 |
119 return ps | 118 return ps |
120 | 119 |
121 def CreateExpectations(self, page_set): | 120 def CreateExpectations(self, page_set): |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
159 | 158 |
160 if '.txt' in test_name: | 159 if '.txt' in test_name: |
161 include_path = os.path.join(current_dir, test_name) | 160 include_path = os.path.join(current_dir, test_name) |
162 test_paths += WebglConformance._ParseTests( | 161 test_paths += WebglConformance._ParseTests( |
163 include_path, version) | 162 include_path, version) |
164 else: | 163 else: |
165 test = os.path.join(current_dir, test_name) | 164 test = os.path.join(current_dir, test_name) |
166 test_paths.append(test) | 165 test_paths.append(test) |
167 | 166 |
168 return test_paths | 167 return test_paths |
OLD | NEW |