#!/usr/bin/env python # -*- coding: utf-8 -*- # All tests that come with piglit, using default settings import os import re import subprocess from framework.core import * from framework.exectest import * from framework.gleantest import * profile = TestProfile() def add_glslparsertest(shader, result): glslparsertest[shader] = PlainExecTest(['../tests/glslparsertest/external-glslparsertest.sh', 'tests/glslparsertest/shaders/' + shader, result]) def add_otherglslparsertest(shader, result, min_glsl_version = '1.10'): glslparsertest[shader] = PlainExecTest(['../tests/glslparsertest/external-glslparsertest.sh', 'tests/glslparsertest/' + shader, result]) execfile(os.path.dirname(__file__) + '/glslparser.tests') profile.tests['glslparsertest'] = glslparsertest def add_otherglslparsertest(shader, result): glslparsertest[shader] = PlainExecTest(['../tests/glslparsertest/external-glslparsertest.sh', 'tests/' + shader, result]) add_otherglslparsertest('shaders/glsl-arb-fragment-coord-conventions-define.frag', 'pass') add_otherglslparsertest('shaders/glsl-color.frag', 'pass') add_otherglslparsertest('shaders/glsl-fs-bug25902.frag', 'pass') add_otherglslparsertest('shaders/glsl-fs-exp2.frag', 'pass') add_otherglslparsertest('shaders/glsl-fs-fragcoord.frag', 'pass') add_otherglslparsertest('shaders/glsl-fs-loop.frag', 'pass') add_otherglslparsertest('shaders/glsl-fs-loop-nested.frag', 'pass') add_otherglslparsertest('shaders/glsl-fs-mix-constant.frag', 'pass') add_otherglslparsertest('shaders/glsl-fs-mix.frag', 'pass') add_otherglslparsertest('shaders/glsl-fs-sqrt-branch.frag', 'pass') add_otherglslparsertest('shaders/glsl-fs-sqrt-zero.frag', 'pass') add_otherglslparsertest('shaders/glsl-mvp.vert', 'pass') add_otherglslparsertest('shaders/glsl-orangebook-ch06-bump.frag', 'pass') add_otherglslparsertest('shaders/glsl-orangebook-ch06-bump.vert', 'pass') add_otherglslparsertest('shaders/glsl-preprocessor-comments.frag', 'pass') add_otherglslparsertest('shaders/glsl-preprocessor-comments.vert', 'pass') add_otherglslparsertest('shaders/glsl-tex-mvp.vert', 'pass') add_otherglslparsertest('shaders/glsl-uniform-update.frag', 'pass') add_otherglslparsertest('shaders/glsl-unused-varying.frag', 'pass') add_otherglslparsertest('shaders/glsl-unused-varying.vert', 'pass') add_otherglslparsertest('shaders/glsl-vs-arrays.vert', 'pass') add_otherglslparsertest('shaders/glsl-vs-functions.vert', 'pass') add_otherglslparsertest('shaders/glsl-vs-if-bool.vert', 'pass') add_otherglslparsertest('shaders/glsl-vs-loop-nested.vert', 'pass') add_otherglslparsertest('shaders/glsl-vs-loop.vert', 'pass') add_otherglslparsertest('shaders/glsl-vs-mov-after-deref.vert', 'pass') add_otherglslparsertest('shaders/glsl-vs-sqrt-zero.vert', 'pass')