X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=grading%2Fuserprog%2Frun-tests;h=b10cb973ebe8c2d59c1d9f0f91a73bd6952d63c5;hb=59bbbf9d74b6c6b430c51def30a9e1437f5e14a1;hp=9384ebad57cdb4a33ef9d393ae7fda424d4575cc;hpb=be193f8d945ee145b404e8b33fae7616a4b408f4;p=pintos-anon diff --git a/grading/userprog/run-tests b/grading/userprog/run-tests index 9384eba..b10cb97 100755 --- a/grading/userprog/run-tests +++ b/grading/userprog/run-tests @@ -20,6 +20,14 @@ our ($test); our (%extra); our ($action); +if ($#ARGV == 0 && $ARGV[0] eq 'null') { + @TESTS = ('null'); + extract_sources (); + build (); + run_and_grade_tests (); + exit success (); +} + parse_cmd_line qw (args-argc args-argv0 args-argvn args-single args-multiple args-dbl-space sc-bad-sp sc-bad-arg sc-boundary @@ -49,10 +57,10 @@ exit if $action eq 'build'; run_and_grade_tests (); write_grades (); write_details (); -exit if $action eq 'test'; +exit success () if $action eq 'test'; assemble_final_grade (); -exit if $action eq 'assemble'; +exit success () if $action eq 'assemble'; die "Don't know how to '$action'"; @@ -162,7 +170,7 @@ sub get_file { . "-v get $guest_fn $host_fn", LOG => "$test/get-$guest_fn", TIMEOUT => 10, - EXPECT => 0); + EXPECT => 1); die "`pintos get $guest_fn' failed - $result\n" if $result ne 'ok'; }