blob: 94d5ed0f727791cec68bb618e375be1ba0e42992 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
#!/usr/bin/perl
if (not -d 'results/') {
mkdir 'results';
}
$c = 0;
for $test (<tests/*.ld>) {
$output = $test;
$output =~ s/^tests/results/;
$output =~ s/\.ld$/.hex/;
unlink $output;
$cmd = "../build/LDMicro /c $test $output";
system $cmd;
$c++;
}
print "\ndifferences follow:\n";
@diff = `diff -q results expected`;
for(@diff) {
print " $_";
}
$fc = scalar @diff;
print "($fc difference(s)/$c)\n";
if($fc == 0) {
print "pass!\n";
exit(0);
} else {
print "FAIL\n";
exit(-1);
}
|