[Piglit] Proposal to embed glslparsertest specifications into shader source files
eric at anholt.net
Tue Nov 30 22:09:12 PST 2010
On Mon, 29 Nov 2010 16:04:47 -0800, Chad Versace <chad at chad-versace.us> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> (A proposal to make Piglit a little easier to use... Please send me your
> The format for glslparsertests is suboptimal; the test specification
> (pass/fail, required GLSL version) is not located in the test file
> itself. This divorce between test and specification causes frequent
> maintenance and testing annoyances (How many times have you opened a
> failing glslparsertest shader file, only to discover that the author
> neglected to comment whether the test should pass or fail?)
> I propose that we embed each test specification into the shader source
> file itself as a specially formatted comment block, and cease to
> register the specifications in /tests/glslparsertest.tests.
> What follows is an overview of the new test file format and of the
> proposal's implementation.
> As for the work involved, it has already been done. In an experimental
> Piglit branch  , all of the below has been implemented and all
> pre-existing glslparertests converted to the new format. No testing
> quirks have been introduced; test results are identical between master
> and the experimental branch.
Sounds pretty nice. Though that gets me to thinking: Maybe for these
parser-test and shader_runner tests, we could have the test harness just
automatically add all the *.shader_test or whatever in the directory as
tests to be run in that directory's group? That way we can add new
tests without typoing the name in all.tests.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 197 bytes
Desc: not available
More information about the Piglit