| OLD | NEW |
| 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 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 | 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 os | 4 import os |
| 5 import platform | |
| 6 | 5 |
| 7 from gpu_tests.gpu_test_expectations import GpuTestExpectations | 6 from gpu_tests.gpu_test_expectations import GpuTestExpectations |
| 8 | 7 |
| 9 # See the GpuTestExpectations class for documentation. | 8 # See the GpuTestExpectations class for documentation. |
| 10 | 9 |
| 11 class WebGLConformanceExpectations(GpuTestExpectations): | 10 class WebGLConformanceExpectations(GpuTestExpectations): |
| 12 def __init__(self, conformance_path): | 11 def __init__(self, conformance_path): |
| 13 self.conformance_path = conformance_path | 12 self.conformance_path = conformance_path |
| 14 super(WebGLConformanceExpectations, self).__init__() | 13 super(WebGLConformanceExpectations, self).__init__() |
| 15 | 14 |
| 16 def Fail(self, pattern, condition=None, bug=None): | 15 def Fail(self, pattern, condition=None, bug=None): |
| 17 self.CheckPatternIsValid(pattern) | 16 self.CheckPatternIsValid(pattern) |
| 18 GpuTestExpectations.Fail(self, pattern, condition, bug) | 17 GpuTestExpectations.Fail(self, pattern, condition, bug) |
| 19 | 18 |
| 20 def Skip(self, pattern, condition=None, bug=None): | 19 def Skip(self, pattern, condition=None, bug=None): |
| 21 self.CheckPatternIsValid(pattern) | 20 self.CheckPatternIsValid(pattern) |
| 22 GpuTestExpectations.Skip(self, pattern, condition, bug) | 21 GpuTestExpectations.Skip(self, pattern, condition, bug) |
| 23 | 22 |
| 24 def CheckPatternIsValid(self, pattern): | 23 def CheckPatternIsValid(self, pattern): |
| 25 # Look for basic wildcards. | 24 # Look for basic wildcards. |
| 26 if not '*' in pattern: | 25 if not '*' in pattern: |
| 27 full_path = os.path.normpath(os.path.join(self.conformance_path, pattern)) | 26 full_path = os.path.normpath(os.path.join(self.conformance_path, pattern)) |
| 28 if not os.path.exists(full_path): | 27 if not os.path.exists(full_path): |
| 29 err_msg = ('The WebGL conformance test path specified in ' + | 28 raise Exception('The WebGL conformance test path specified in ' + |
| 30 'expectation does not exist: ' + full_path) | 29 'expectation does not exist: ' + full_path) |
| 31 # Seeing problems on some Windows bots where the full path doesn't | |
| 32 # seem to exist if it's over 255 characters. http://crbug.com/599333 | |
| 33 if platform.system().startswith('Windows') and len(full_path) > 255: | |
| 34 print err_msg | |
| 35 else: | |
| 36 raise Exception(err_msg) | |
| 37 | 30 |
| 38 def SetExpectations(self): | 31 def SetExpectations(self): |
| 39 # Fails on all platforms | 32 # Fails on all platforms |
| 40 self.Fail('deqp/data/gles2/shaders/functions.html', | 33 self.Fail('deqp/data/gles2/shaders/functions.html', |
| 41 bug=478572) | 34 bug=478572) |
| 42 self.Fail('deqp/data/gles2/shaders/scoping.html', | 35 self.Fail('deqp/data/gles2/shaders/scoping.html', |
| 43 bug=478572) | 36 bug=478572) |
| 44 self.Fail('conformance/extensions/ext-sRGB.html', | 37 self.Fail('conformance/extensions/ext-sRGB.html', |
| 45 bug=540900) | 38 bug=540900) |
| 46 | 39 |
| (...skipping 383 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 430 self.Fail('conformance/textures/misc/texture-npot.html', | 423 self.Fail('conformance/textures/misc/texture-npot.html', |
| 431 ['chromeos', ('intel', 0xa011)], bug=375554) | 424 ['chromeos', ('intel', 0xa011)], bug=375554) |
| 432 self.Fail('conformance/textures/misc/texture-npot-video.html', | 425 self.Fail('conformance/textures/misc/texture-npot-video.html', |
| 433 ['chromeos', ('intel', 0xa011)], bug=375554) | 426 ['chromeos', ('intel', 0xa011)], bug=375554) |
| 434 self.Fail('conformance/textures/misc/texture-size.html', | 427 self.Fail('conformance/textures/misc/texture-size.html', |
| 435 ['chromeos', ('intel', 0xa011)], bug=375554) | 428 ['chromeos', ('intel', 0xa011)], bug=375554) |
| 436 self.Fail('conformance/uniforms/gl-uniform-arrays.html', | 429 self.Fail('conformance/uniforms/gl-uniform-arrays.html', |
| 437 ['chromeos', ('intel', 0xa011)], bug=375554) | 430 ['chromeos', ('intel', 0xa011)], bug=375554) |
| 438 self.Skip('conformance/uniforms/uniform-default-values.html', | 431 self.Skip('conformance/uniforms/uniform-default-values.html', |
| 439 ['chromeos', ('intel', 0xa011)], bug=375554) | 432 ['chromeos', ('intel', 0xa011)], bug=375554) |
| OLD | NEW |