[Piglit] [PATCH 5/4] glsl: Make core-profile-define tests a bit more robust.
Kenneth Graunke
kenneth at whitecape.org
Wed Aug 28 12:54:56 PDT 2013
They now actually detect that GL_core_profile is a #define, rather than
a built-in constant, and also ensure that the value is 1, as required by
the spec.
Suggested-by: Ian Romanick <ian.d.romanick at intel.com>
Signed-off-by: Kenneth Graunke <kenneth at whitecape.org>
---
tests/spec/glsl-1.50/compiler/profiles/core-profile-define.frag | 9 ++++++++-
tests/spec/glsl-3.30/compiler/profiles/core-profile-define.frag | 9 ++++++++-
2 files changed, 16 insertions(+), 2 deletions(-)
I forgot to update these too.
diff --git a/tests/spec/glsl-1.50/compiler/profiles/core-profile-define.frag b/tests/spec/glsl-1.50/compiler/profiles/core-profile-define.frag
index 13d0100..9e7b8b7 100644
--- a/tests/spec/glsl-1.50/compiler/profiles/core-profile-define.frag
+++ b/tests/spec/glsl-1.50/compiler/profiles/core-profile-define.frag
@@ -4,4 +4,11 @@
// [end config]
#version 150
-int x = GL_core_profile;
+#if !defined GL_core_profile
+#error GL_core_profile not defined.
+#endif
+#if GL_core_profile != 1
+#error GL_core_profile is not 1.
+#endif
+
+void main() { }
diff --git a/tests/spec/glsl-3.30/compiler/profiles/core-profile-define.frag b/tests/spec/glsl-3.30/compiler/profiles/core-profile-define.frag
index 68d3d0c..4a5b9ed 100644
--- a/tests/spec/glsl-3.30/compiler/profiles/core-profile-define.frag
+++ b/tests/spec/glsl-3.30/compiler/profiles/core-profile-define.frag
@@ -4,4 +4,11 @@
// [end config]
#version 330
-int x = GL_core_profile;
+#if !defined GL_core_profile
+#error GL_core_profile not defined.
+#endif
+#if GL_core_profile != 1
+#error GL_core_profile is not 1.
+#endif
+
+void main() { }
--
1.8.3.4
More information about the Piglit
mailing list