6
for t in if1 if2 if3 if4 if5; do
10
if [ ! -f ${srcdir}/${t}.c.expout ]; then
11
echo FAILED: EXPOUT: ../src/unifdef -DFOO=1 -DFOOB=42 -UBAR ${srcdir}/${t}.c
12
echo Test Framework Error: Missing ${srcdir}/${t}.c.expout 1>&2
15
if [ ! -f ${srcdir}/${t}.c.experr ]; then
16
echo FAILED: EXPERR: ../src/unifdef -DFOO=1 -DFOOB=42 -UBAR ${srcdir}/${t}.c
17
echo Test Framework Error: Missing ${srcdir}/${t}.c.experr 1>&2
21
../src/unifdef -DFOO=1 -DFOOB=42 -UBAR ${srcdir}/${t}.c >${t}.out 2>${t}.err
24
echo FAILED: RC: ../src/unifdef -DFOO=1 -DFOOB=42 -UBAR ${srcdir}/${t}.c
25
echo Error: exit code zero when changes exist. 1>&2
30
if ! cmp -s ${t}.out ${srcdir}/${t}.c.expout; then
31
echo FAILED: OUT: ../src/unifdef -DFOO=1 -DFOOB=42 -UBAR ${srcdir}/${t}.c
32
echo Standard output differences $t
33
diff ${t}.out ${srcdir}/${t}.c.expout
37
if ! cmp -s ${t}.err ${srcdir}/${t}.c.experr; then
38
echo FAILED: ERR: ../src/unifdef -DFOO=1 -DFOOB=42 -UBAR ${srcdir}/${t}.c
39
echo Standard error differences $t
40
diff ${t}.out ${srcdir}/${t}.c.expout
46
rm -f ${t}.out ${t}.err