]> git.ipfire.org Git - thirdparty/bash.git/blob - tests/run-minimal
bash-5.0 distribution sources and documentation
[thirdparty/bash.git] / tests / run-minimal
1 #! /bin/sh
2 #
3 # run-minimal - a version of run-all for shells configured with
4 # --enable-minimal-config
5 #
6
7 : ${TMPDIR:=/tmp}
8 export TMPDIR
9
10 # basic /bin/sh syntax
11 SUFFIX=`${THIS_SH} -c 'echo $(( $RANDOM + $BASHPID ))'`
12
13 BASH_TSTOUT=${TMPDIR}/bashtst-$SUFFIX # for now
14 export BASH_TSTOUT
15
16 trap 'rm -f $BASH_TSTOUT' 0
17
18 PATH=.:$PATH # just to get the right version of printenv
19 export PATH
20
21 # unset BASH_ENV only if it is set
22 [ "${BASH_ENV+set}" = "set" ] && unset BASH_ENV
23 # ditto for SHELLOPTS
24 #[ "${SHELLOPTS+set}" = "set" ] && unset SHELLOPTS
25
26 : ${THIS_SH:=../bash}
27 export THIS_SH
28
29 ${THIS_SH} ./version.mini
30
31 rm -f "$BASH_TSTOUT"
32
33 echo Testing ${THIS_SH}
34 echo Any output from any test, unless otherwise noted, indicates a possible anomaly
35 for x in run-*
36 do
37 case $x in
38 $0) ;;
39 *.orig|*~) ;;
40 run-dollars|run-execscript|run-func|run-getopts|run-heredoc) echo $x ; sh $x ;;
41 run-ifs-tests|run-input-test|run-invert|run-more-exp|run-nquote) echo $x ; sh $x ;;
42 run-ifs-posix|run-posix2|run-posixpat|run-posixpipe) echo $x ; sh $x ;;
43 run-precedence|run-quote|run-read|run-rhs-exp|run-strip|run-tilde) echo $x ; sh $x ;;
44 run-dynvar) echo $x ; sh $x ;;
45 ;;
46 *) ;;
47 esac
48 rm -f "$BASH_TSTOUT"
49 done
50
51 exit 0