]> mj.ucw.cz Git - moe.git/blobdiff - bin/lib
Added.
[moe.git] / bin / lib
diff --git a/bin/lib b/bin/lib
index 37461da8e8c618a050dce81c1d847bb3c797a49f..537bf58764c8d81ed514e65bf49d1c71b3967c97 100644 (file)
--- a/bin/lib
+++ b/bin/lib
@@ -48,7 +48,7 @@ function box-init
                mkdir -p box
        else
                pcont "used account $TEST_USER, "
-               BOXDIR=$MO_ROOT/$TEST_USER
+               BOXDIR=$MO_ROOT/eval/$TEST_USER
                BOXCMD=bin/box-$TEST_USER
        fi
        [ -d $BOXDIR -a -f $BOXCMD ] || die "Sandbox set up incorrectly"
@@ -190,9 +190,14 @@ function test-run-file
        fi
        cat $TDIR/exec.out
        rm $TDIR/exec.out
+       test-fetch-output || return 1
+}
+
+function test-fetch-output
+{
        echo "Output files:"
        ls -Al $BOXDIR
-       if [ ! -s $BOXDIR/$PROBLEM.out ] ; then
+       if [ ! -f $BOXDIR/$PROBLEM.out ] ; then
                pend "No output file."
                echo "No output file."
                echo >>$PTSFILE "0 No output."
@@ -234,6 +239,7 @@ function test-run-interactive
        fi
        cat $TDIR/exec.out
        rm $TDIR/exec.out
+       [ -z "$OUTPUT_CHECK" ] || test-fetch-output || return 1
 }
 
 # Syntax checks