X-Git-Url: http://git.ieval.ro/?p=gruntmaster-daemon.git;a=blobdiff_plain;f=lib%2FGruntmaster%2FDaemon%2FRunner%2FFile.pm;h=34ea04d80558fb13b7d7d13f41a401c2a0c14d0d;hp=6fc66c2b00631dc6b6207bbd22b9042f90f4d50a;hb=8a8d1a82a2a778c546569ea1e6745be4594a0ff5;hpb=6d590c603e3b14f1dc198e3635a85543565d1016 diff --git a/lib/Gruntmaster/Daemon/Runner/File.pm b/lib/Gruntmaster/Daemon/Runner/File.pm index 6fc66c2..34ea04d 100644 --- a/lib/Gruntmaster/Daemon/Runner/File.pm +++ b/lib/Gruntmaster/Daemon/Runner/File.pm @@ -17,7 +17,12 @@ sub run{ get_logger->trace("Running on test $test..."); $meta->{files}{prog}{run}->($meta->{files}{prog}{name}, fds => [qw/0 input 1 >output/], map {defined $meta->{$_} ? ($_ => $meta->{$_}) : () } qw/timeout olimit mlimit/); my $out = slurp 'output'; - my $ok = $meta->{okfile}[$test - 1]; + my $ok; + if (exists $meta->{okfile}) { + $ok = $meta->{okfile}[$test - 1] + } else { + $ok = slurp "/var/lib/gruntmasterd/pb/$meta->{problem}/$test.ok" + } $out =~ s/^\s+//; $ok =~ s/^\s+//;