xref: /freebsd/bin/sh/tests/expansion/pathname6.0 (revision 43a5ec4eb41567cc92586503212743d89686d78f)
1# $FreeBSD$
2
3unset LC_ALL
4LC_COLLATE=en_US.US-ASCII
5export LC_COLLATE
6
7failures=0
8
9check() {
10	testcase=$1
11	expect=$2
12	eval "set -- $testcase"
13	actual="$*"
14	if [ "$actual" != "$expect" ]; then
15		failures=$((failures+1))
16		printf '%s\n' "For $testcase, expected $expect actual $actual"
17	fi
18}
19
20set -e
21T=$(mktemp -d ${TMPDIR:-/tmp}/sh-test.XXXXXX)
22trap 'rm -rf $T' 0
23cd -P $T
24
25touch A B a b
26
27check '*' 'a A b B'
28
29exit $((failures != 0))
30