diff options
author | Ian Romanick <ian.d.romanick@intel.com> | 2016-08-24 20:31:44 +0100 |
---|---|---|
committer | Ian Romanick <ian.d.romanick@intel.com> | 2016-09-01 10:59:05 -0700 |
commit | 89c8851d2227fde3aeda3682fd148f96c750be68 (patch) | |
tree | a6e7626e4c639e0589a6d234769f384a0fb2bae4 | |
parent | 1daaf91fe994b63f5832d072fcbcd4175a65e317 (diff) |
glsl: Verify that #version 0 generates an error instead of crashing
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=97420
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
-rw-r--r-- | tests/spec/glsl-1.10/compiler/version-0.frag | 8 | ||||
-rw-r--r-- | tests/spec/glsl-1.10/compiler/version-0.vert | 8 | ||||
-rw-r--r-- | tests/spec/glsl-es-3.00/compiler/version-0.frag | 8 | ||||
-rw-r--r-- | tests/spec/glsl-es-3.00/compiler/version-0.vert | 8 |
4 files changed, 32 insertions, 0 deletions
diff --git a/tests/spec/glsl-1.10/compiler/version-0.frag b/tests/spec/glsl-1.10/compiler/version-0.frag new file mode 100644 index 000000000..9e9ac764e --- /dev/null +++ b/tests/spec/glsl-1.10/compiler/version-0.frag @@ -0,0 +1,8 @@ +// [config] +// expect_result: fail +// glsl_version: 1.10 +// [end config] + +#version 0 + +void main() { gl_FragColor = vec4(0); } diff --git a/tests/spec/glsl-1.10/compiler/version-0.vert b/tests/spec/glsl-1.10/compiler/version-0.vert new file mode 100644 index 000000000..d01013701 --- /dev/null +++ b/tests/spec/glsl-1.10/compiler/version-0.vert @@ -0,0 +1,8 @@ +// [config] +// expect_result: fail +// glsl_version: 1.10 +// [end config] + +#version 0 + +void main() { gl_Position = vec4(0); } diff --git a/tests/spec/glsl-es-3.00/compiler/version-0.frag b/tests/spec/glsl-es-3.00/compiler/version-0.frag new file mode 100644 index 000000000..126dcab9d --- /dev/null +++ b/tests/spec/glsl-es-3.00/compiler/version-0.frag @@ -0,0 +1,8 @@ +// [config] +// expect_result: fail +// glsl_version: 3.00 +// [end config] + +#version 0 es + +void main() { } diff --git a/tests/spec/glsl-es-3.00/compiler/version-0.vert b/tests/spec/glsl-es-3.00/compiler/version-0.vert new file mode 100644 index 000000000..1383fe3a9 --- /dev/null +++ b/tests/spec/glsl-es-3.00/compiler/version-0.vert @@ -0,0 +1,8 @@ +// [config] +// expect_result: fail +// glsl_version: 3.00 +// [end config] + +#version 0 es + +void main() { gl_Position = vec4(0); } |