am-ft: make the environment available earlier
[platform/upstream/automake.git] / t / tap-passthrough-exit.sh
old mode 100755 (executable)
new mode 100644 (file)
index 6014cc5..cf9ea46
@@ -1,5 +1,5 @@
 #! /bin/sh
-# Copyright (C) 2011-2012 Free Software Foundation, Inc.
+# Copyright (C) 2011-2013 Free Software Foundation, Inc.
 #
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -17,9 +17,9 @@
 # TAP support:
 #  - non-success exit status of a test script is reported in the
 #    log file
-# See also related test 'tap-passthrough.test'.
+# See also related test 'tap-passthrough.sh'.
 
-. ./defs || Exit 1
+. test-init.sh
 
 cat > Makefile.am << 'END'
 TEST_LOG_COMPILER = $(SHELL)
@@ -38,13 +38,13 @@ END
   echo TESTS += exit-$e.test >> Makefile.am
 done
 
-. "$am_testauxdir"/tap-setup.sh || fatal_ "sourcing tap-setup.sh"
+. tap-setup.sh
 
 st=0
 $MAKE check || st=$?
 for e in $exit_statuses; do cat exit-$e.log; done
 cat test-suite.log
-test $st -gt 0 || Exit 1
+test $st -gt 0 || exit 1
 
 for e in $exit_statuses; do
   for log in exit-$e.log test-suite.log; do
@@ -52,7 +52,7 @@ for e in $exit_statuses; do
   done
 done
 
-env TEST_LOG_DRIVER_FLAGS='--ignore-exit' $MAKE -e check
-$FGREP ".test - exited with status" *.log && Exit 1
+run_make check TEST_LOG_DRIVER_FLAGS='--ignore-exit'
+$FGREP ".test - exited with status" *.log && exit 1
 
 :