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