Add new check item cmdcheck to run script to check auto-test result
This commit is contained in:
parent
e68ce246df
commit
2ff5605034
@ -477,10 +477,11 @@ sub loadcase
|
||||
$j = -1;
|
||||
$cases[$i]={};
|
||||
$cases[$i]->{name}=$name;
|
||||
$cases[$i]->{filename}=$file;
|
||||
$cases[$i]->{filename}=$file;
|
||||
if(!$needshow){
|
||||
$cases[$i]->{cmd}=[];
|
||||
$cases[$i]->{check}=[];
|
||||
$cases[$i]->{cmdcheck}=[];
|
||||
push(@rightcase, $name);
|
||||
}else{
|
||||
$skip = 1;
|
||||
@ -545,6 +546,14 @@ sub loadcase
|
||||
return 1;
|
||||
}
|
||||
$z = $z + 1;
|
||||
}elsif($line =~ /^cmdcheck\s*:\s*(\w.+)/){
|
||||
next if $skip;
|
||||
$cases[$i]->{cmdcheck}->[$j][$z] = &getvar($1);
|
||||
if($cases[$i]->{cmdcheck}->[$j][$z] eq ''){
|
||||
close(FILE);
|
||||
return 1;
|
||||
}
|
||||
$z = $z + 1;
|
||||
}elsif($line =~ /^end/){
|
||||
next if $skip;
|
||||
$i = $i + 1;
|
||||
@ -756,6 +765,9 @@ sub runcase
|
||||
}
|
||||
}
|
||||
}
|
||||
foreach my $cmdcheck (@{$$case{cmdcheck}->[$j]}){
|
||||
&runcmd($cmdcheck);
|
||||
}
|
||||
$j = $j + 1;
|
||||
}
|
||||
my $now2=timelocal(localtime());
|
||||
|
Loading…
Reference in New Issue
Block a user