summary refs log tree commit diff
path: root/bin/cash/tests/expansion/export3.0
diff options
context:
space:
mode:
Diffstat (limited to 'bin/cash/tests/expansion/export3.0')
-rw-r--r--bin/cash/tests/expansion/export3.030
1 files changed, 30 insertions, 0 deletions
diff --git a/bin/cash/tests/expansion/export3.0 b/bin/cash/tests/expansion/export3.0
new file mode 100644
index 00000000..abe137a3
--- /dev/null
+++ b/bin/cash/tests/expansion/export3.0
@@ -0,0 +1,30 @@
+# $FreeBSD: releng/12.0/bin/sh/tests/expansion/export3.0 238468 2012-07-15 10:19:43Z jilles $
+
+w='@ @'
+check() {
+	[ "$v" = "$w" ] || echo "Expected $w got $v"
+}
+
+command export v=$w
+check
+command command export v=$w
+check
+
+HOME=/known/value
+check() {
+	[ "$v" = ~ ] || echo "Expected $HOME got $v"
+}
+
+command export v=~
+check
+command command export v=~
+check
+
+check() {
+	[ "$v" = "x:$HOME" ] || echo "Expected x:$HOME got $v"
+}
+
+command export v=x:~
+check
+command command export v=x:~
+check