summaryrefslogtreecommitdiff
path: root/unit-tests/varname-dot-shell.exp
diff options
context:
space:
mode:
Diffstat (limited to 'unit-tests/varname-dot-shell.exp')
-rwxr-xr-xunit-tests/varname-dot-shell.exp19
1 files changed, 19 insertions, 0 deletions
diff --git a/unit-tests/varname-dot-shell.exp b/unit-tests/varname-dot-shell.exp
new file mode 100755
index 0000000000000..af4baaf44c0bb
--- /dev/null
+++ b/unit-tests/varname-dot-shell.exp
@@ -0,0 +1,19 @@
+ParseReadLine (8): 'ORIG_SHELL:= ${.SHELL}'
+Var_Parse: ${.SHELL} with VARE_WANTRES|VARE_ASSIGN
+Global:delete .SHELL (not found)
+Command:.SHELL = (details omitted)
+ParseReadLine (10): '.SHELL= overwritten'
+Global:.SHELL = overwritten
+Var_Parse: ${.SHELL} != ${ORIG_SHELL} with VARE_UNDEFERR|VARE_WANTRES
+ParseReadLine (18): '.undef .SHELL'
+Global:delete .SHELL
+ParseReadLine (19): '.SHELL= newly overwritten'
+Global:.SHELL = newly overwritten
+Var_Parse: ${.SHELL} != ${ORIG_SHELL} with VARE_UNDEFERR|VARE_WANTRES
+ParseReadLine (24): 'all:'
+ParseReadLine (25): ' @echo ${.SHELL:M*}'
+Var_Parse: ${.SHELL:M*} with VARE_WANTRES
+Applying ${.SHELL:M...} to "(details omitted)" (eflags = VARE_WANTRES, vflags = VAR_READONLY)
+Pattern[.SHELL] for [(details omitted)] is [*]
+Result of ${.SHELL:M*} is "(details omitted)" (eflags = VARE_WANTRES, vflags = VAR_READONLY)
+exit status 0