xref: /freebsd/bin/sh/tests/expansion/local1.0 (revision cd0d51baaa4509a1db83251a601d34404d20c990)
1# $FreeBSD$
2
3run_test() {
4	w='@ @'
5	check() {
6		[ "$v" = "$w" ] || echo "Expected $w got $v"
7	}
8
9	local v=$w
10	check
11
12	HOME=/known/value
13	check() {
14		[ "$v" = ~ ] || echo "Expected $HOME got $v"
15	}
16
17	local v=~
18	check
19
20	check() {
21		[ "$v" = "x:$HOME" ] || echo "Expected x:$HOME got $v"
22	}
23
24	local v=x:~
25	check
26}
27
28run_test
29