| 1 | #! /bin/shscip-shell filesystem . . `/bin/sh`. |
| 2 | progname=`basenamescip-shell system . . basename. $0` |
| 3 | |
| 4 | if [scip-shell system . . `[`. -f ns ] ; then |
| 5 | PROG=./ns |
| 6 | elif [scip-shell system . . `[`. -f ns.dyn ] ; then |
| 7 | PROG=./ns.dyn |
| 8 | fi |
| 9 | |
| 10 | rmscip-shell system . . rm. -f out.tr all.tr core |
| 11 | echoscip-shell system . . echo. $PROG tcl/test/test-suite-$1.tcl $2 $3 |
| 12 | if $PROG tcl/test/test-suite-$1.tcl $2 $3 ; then |
| 13 | if [scip-shell system . . `[`. ! -f out.tr ] ; then |
| 14 | echoscip-shell system . . echo. "$progname: no output?" 1>&2 |
| 15 | else |
| 16 | if [scip-shell system . . `[`. -n "$DISPLAY" ] ; then |
| 17 | raw2xg -m 90 -s 0.01 out.tr | xgraph |
| 18 | else |
| 19 | file=`perlscip-shell system . . perl. -ane '$F[2] =~ s/test_// ; $F[2] =~ s/_/-/g; print $F[2]; exit' out.tr` |
| 20 | raw2gp -a out.tr | gnuplot |
| 21 | echoscip-shell system . . echo. "$progname: postscript of graph is in $file.ps" |
| 22 | fi |
| 23 | fi |
| 24 | elif [scip-shell system . . `[`. -f core ] ; then |
| 25 | echoscip-shell system . . echo. "$progname: core dump" 1>&2 |
| 26 | fi |