7 [ -n "$RUBY" ] || RUBY
=ruby
9 # run_test program expected_output
16 echo "FAIL: exit status is $s"
17 errors
=$
((errors
+ 1))
18 elif [ "$output" != "$3" ]
20 echo "FAIL: wrong output"
21 errors
=$
((errors
+ 1))
28 run_test
"$1" "./$1" "$2"
32 run_test2
"$1" "`cat $1.out`"
35 run_test2 hello
"Hello, world!"
43 run_test2 fact
479001600
63 run_test2 tail-calls
''
69 printf 'test_output_name...'
70 $RUBY test_output_name.rb
71 [ $?
-eq 0 ] || errors
=$
((errors
+ 1))
77 echo "$errors tests failed"