[Piglit] [PATCH 2/4] GL_ARB_sampler_objects/sampler-objects: Use piglit_require_extension()

Eric Anholt eric at anholt.net
Wed Aug 1 16:04:03 PDT 2012


This gives us nicer skip messages if the extension isn't present.
---
 tests/spec/arb_sampler_objects/sampler-objects.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/tests/spec/arb_sampler_objects/sampler-objects.c b/tests/spec/arb_sampler_objects/sampler-objects.c
index 86679db..f7937be 100644
--- a/tests/spec/arb_sampler_objects/sampler-objects.c
+++ b/tests/spec/arb_sampler_objects/sampler-objects.c
@@ -246,8 +246,7 @@ piglit_display(void)
 void
 piglit_init(int argc, char**argv)
 {
-   if (!piglit_is_extension_supported("GL_ARB_sampler_objects"))
-      piglit_report_result(PIGLIT_SKIP);
+   piglit_require_extension("GL_ARB_sampler_objects");
 
    piglit_ortho_projection(piglit_width, piglit_height, GL_FALSE);
 }
-- 
1.7.10.4



More information about the Piglit mailing list