]>
Commit | Line | Data |
---|---|---|
d696c285 A |
1 | #!/usr/bin/perl -w |
2 | ||
3 | # | |
4 | # Usage: | |
5 | # | |
6 | # ${FALL_IFF} command | |
7 | # | |
8 | ||
9 | use strict; | |
10 | ||
11 | my $test_name = ""; | |
12 | if ( exists $ENV{UNIT_TEST_NAME} ) { | |
13 | $test_name = $ENV{UNIT_TEST_NAME}; | |
14 | } | |
15 | ||
a61fdf0a A |
16 | my $ret = system(@ARGV); |
17 | my $exit_value = $ret >> 8; | |
18 | my $signal_num = $ret & 127; | |
19 | my $dumped_core = $ret & 128; | |
20 | my $crashed = $signal_num + $dumped_core; | |
21 | ||
22 | if(0 == $exit_value || 0 != $crashed) | |
d696c285 A |
23 | { |
24 | printf("FAIL $test_name\n"); | |
a61fdf0a | 25 | exit 1; |
d696c285 | 26 | } |
d696c285 | 27 | |
a61fdf0a A |
28 | printf("PASS $test_name\n"); |
29 | exit 0; |