[Piglit] [PATCH 1/2] Require [require] section in .shader_test files.

Stuart Abercrombie sabercrombie at chromium.org
Wed Feb 6 17:04:25 PST 2013


A step toward removing explicit #version directives.

Signed-off-by: Stuart Abercrombie <sabercrombie at chromium.org>
---
 tests/shaders/shader_runner.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/tests/shaders/shader_runner.c b/tests/shaders/shader_runner.c
index d83228e..eab48f3 100644
--- a/tests/shaders/shader_runner.c
+++ b/tests/shaders/shader_runner.c
@@ -915,6 +915,11 @@ parse_required_versions(struct requirement_parse_results *results,
 
 	free(text);
 
+	if (!in_requirement_section) {
+		printf("[require] section missing\n");
+		piglit_report_result(PIGLIT_FAIL);
+	}
+
 	if (results->found_glsl && results->glsl_version.es && !results->found_gl) {
 		printf("%s", "The test specifies a requirement for GLSL ES, "
 		       "but specifies no GL requirement\n.");
-- 
1.8.1



More information about the Piglit mailing list