]>
The Tcpdump Group git mirrors - tcpdump/blob - tests/TESTonce
3 system("mkdir -p NEW DIFF");
6 print "Usage: TESTonce name input output options\n";
15 $r = system "../tcpdump 2>/dev/null -n -r $input $options | tee NEW/$output | diff -w $output - >DIFF/$output.diff";
18 printf " %-30s: passed\n", $name;
19 unlink "DIFF/$output.diff";
22 printf " %-30s: TEST FAILED", $name;
23 open FOUT
, '>>failure-outputs.txt';
24 printf FOUT
"Failed test: $name\n\n";
26 system "cat DIFF/$output.diff >> failure-outputs.txt";
29 print " (failed to execute: $!)\n";
33 printf " (terminated with signal %u, %s coredump)\n", ($r & 127), ($r & 128) ?
'with' : 'without';
34 exit ($r & 128) ?
10 : 20;