checkresult
 1  #!/bin/sh
 2  
 3  STDERR=$(dirname $1)/stderr
 4  if [ ! -f $STDERR ]; then
 5      echo "stderr file not found!"
 6      exit 1
 7  fi
 8  
 9  # Linux spelling of ERANGE
10  if egrep -q 'rtapi_app_main_fails.* Numerical result out of range' $STDERR; then
11      echo "loadrt found the test component, and it failed to load"
12      exit 0
13  fi
14  
15  # FreeBSD spelling of ERANGE
16  if egrep -q 'rtapi_app_main_fails.* Result too large' $STDERR; then
17      echo "loadrt found the test component, and it failed to load"
18      exit 0
19  fi
20  
21  echo "loadrt did not find the test component"
22  exit 1