fbo-fragcoord2: Convert asserts to failure reports.

Submitted by Vinson Lee on March 9, 2016, 3:17 a.m.

Details

Message ID 1457493463-32193-1-git-send-email-vlee@freedesktop.org
State New
Headers show
Series "fbo-fragcoord2: Convert asserts to failure reports." ( rev: 1 ) in Piglit

Not browsing as part of any series.

Commit Message

Vinson Lee March 9, 2016, 3:17 a.m.
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
---
 tests/fbo/fbo-fragcoord2.c | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

Patch hide | download patch | download mbox

diff --git a/tests/fbo/fbo-fragcoord2.c b/tests/fbo/fbo-fragcoord2.c
index 34a5c6cf7802..e816a9800cd6 100644
--- a/tests/fbo/fbo-fragcoord2.c
+++ b/tests/fbo/fbo-fragcoord2.c
@@ -220,11 +220,17 @@  piglit_init(int argc, char**argv)
    piglit_ortho_projection(piglit_width, piglit_height, GL_FALSE);
 
    vs = piglit_compile_shader_text(GL_VERTEX_SHADER, VertShaderText);
-   assert(vs);
+   if (!vs) {
+      piglit_report_result(PIGLIT_FAIL);
+   }
 
    fs = piglit_compile_shader_text(GL_FRAGMENT_SHADER, FragShaderText);
-   assert(fs);
+   if (!fs) {
+      piglit_report_result(PIGLIT_FAIL);
+   }
 
    prog = piglit_link_simple_program(vs, fs);
-   assert(prog);
+   if (!prog) {
+      piglit_report_result(PIGLIT_FAIL);
+   }
 }