2017-08-04 12:25:20 +08:00
|
|
|
|
|
|
|
####################
|
2017-08-02 11:58:40 +08:00
|
|
|
# Verify behavior of `set --show` given an invalid var name
|
2017-08-04 12:25:20 +08:00
|
|
|
|
|
|
|
####################
|
2017-08-02 11:58:40 +08:00
|
|
|
# Verify behavior of `set --show`
|
|
|
|
$var1: not set in local scope
|
|
|
|
$var1: not set in global scope
|
|
|
|
$var1: set in universal scope, unexported, with 1 elements
|
|
|
|
$var1[0]: length=5 value=|hello|
|
|
|
|
|
|
|
|
$var1: set in local scope, unexported, with 0 elements
|
|
|
|
$var1: set in global scope, unexported, with 2 elements
|
|
|
|
$var1[0]: length=7 value=|goodbye|
|
|
|
|
$var1[1]: length=19 value=|and don\'t come back|
|
|
|
|
$var1: set in universal scope, unexported, with 1 elements
|
|
|
|
$var1[0]: length=5 value=|hello|
|
|
|
|
|
|
|
|
$_unset_var: not set in local scope
|
|
|
|
$_unset_var: not set in global scope
|
|
|
|
$_unset_var: not set in universal scope
|
|
|
|
|
|
|
|
$var2: not set in local scope
|
|
|
|
$var2: set in global scope, unexported, with 0 elements
|
|
|
|
$var2: not set in universal scope
|
|
|
|
|