[Piglit] [RFC v2 14/39] all.py: Replace use of add_glsl_parser_test with import_glsl_parser_test

Dylan Baker baker.dylan.c at gmail.com
Mon Feb 2 17:37:19 PST 2015


Signed-off-by: Dylan Baker <dylanx.c.baker at intel.com>
---
 tests/all.py | 28 ++++++++--------------------
 1 file changed, 8 insertions(+), 20 deletions(-)

diff --git a/tests/all.py b/tests/all.py
index 6c05dc6..3556a6a 100644
--- a/tests/all.py
+++ b/tests/all.py
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 # All tests that come with piglit, using default settings
-#
+
 __all__ = ['profile']
 
 import itertools
@@ -3296,7 +3296,7 @@ oes_matrix_get['All queries'] = PiglitGLTest(['oes_matrix_get-api'], run_concurr
 oes_fixed_point = spec['OES_fixed_point']
 oes_fixed_point['attribute-arrays'] = PiglitGLTest(['oes_fixed_point-attribute-arrays'], run_concurrent=True)
 
-spec['OES_standard_derivatives'] = import_glsl_parser_tests(spec['OES_standard_derivatives'],
+import_glsl_parser_tests(spec['OES_standard_derivatives'],
                          os.path.join(TESTS_DIR, 'spec', 'oes_standard_derivatives'),
                          ['compiler'])
 
@@ -3540,24 +3540,12 @@ arb_compute_shader['built-in constants'] = PiglitGLTest(
      os.path.join(TESTS_DIR, 'spec', 'arb_compute_shader', 'minimum-maximums.txt')],
     run_concurrent=True)
 
-# group glslparsertest ------------------------------------------------------
-glslparsertest = profile.tests['glslparsertest']
-# Add all shader source files in the directories below.
-for filename in os.listdir(os.path.join(TESTS_DIR, 'glslparsertest', 'shaders')):
-    ext = filename.rsplit('.')[-1]
-    if ext in ['vert', 'geo', 'frag']:
-        add_glsl_parser_test(
-            glslparsertest,
-            os.path.join(TESTS_DIR, 'glslparsertest', 'shaders', filename),
-            filename)
-for filename in os.listdir(os.path.join(TESTS_DIR, 'glslparsertest', 'glsl2')):
-    ext = filename.rsplit('.')[-1]
-    if ext in ['vert', 'geo', 'frag']:
-        add_glsl_parser_test(
-            glslparsertest,
-            os.path.join(TESTS_DIR, 'glslparsertest', 'glsl2', filename), 
-            grouptools.join('glsl2', filename))
-# end group glslparsertest ---------------------------------------------------
+import_glsl_parser_tests(profile.tests['glslparsertest']['glsl2'],
+                         os.path.join(TESTS_DIR, 'glslparsertest', 'glsl2'),
+                         [''])
+import_glsl_parser_tests(profile.tests['glslparsertest'],
+                         os.path.join(TESTS_DIR, 'glslparsertest', 'shaders'),
+                         [''])
 
 hiz = profile.tests['hiz']
 add_plain_test(hiz, ['hiz-depth-stencil-test-fbo-d0-s8'])
-- 
2.2.2



More information about the Piglit mailing list