From 99a3c59fae0f69a42370419130e815aaff6f540e Mon Sep 17 00:00:00 2001 From: John Kessenich Date: Tue, 16 Jun 2015 18:40:40 +0000 Subject: [PATCH] glslang tests: Fix error propagation. From David Neto . The problem is that putting the while loop at the end of a pipeline was hiding any errors being generated by those tests. The patch changes the script to use a case statement inside the while loop instead of "grep" on the outside. git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@31503 e7fa87d3-cd2b-0410-9028-fcbf551c1848 --- Test/runtests | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/Test/runtests b/Test/runtests index 94b805b4..be14ee03 100755 --- a/Test/runtests +++ b/Test/runtests @@ -40,12 +40,19 @@ fi # # SPIR-V code generation tests # -grep -v "^#" test-spirv-list | while read t; do - echo Running SPIR-V $t... - b=`basename $t` - $EXE -H $t > $TARGETDIR/$b.out - diff -b $BASEDIR/$b.out $TARGETDIR/$b.out || HASERROR=1 -done +while read t; do + case $t in + \#*) + # Skip comment lines in the test list file. + ;; + *) + echo Running SPIR-V $t... + b=`basename $t` + $EXE -H $t > $TARGETDIR/$b.out + diff -b $BASEDIR/$b.out $TARGETDIR/$b.out || HASERROR=1 + ;; + esac +done < test-spirv-list # # grouped shaders for bulk (faster) tests