diff --git a/tests/test3.in b/tests/test3.in index 92cc1c86c..f370c97b3 100644 --- a/tests/test3.in +++ b/tests/test3.in @@ -217,4 +217,20 @@ end # clear foo for other shells set -eU foo + +# Test behavior of universals on startup (#1526) +echo Testing Universal Startup +set -U testu 0 +../fish -c 'set -U testu 1' +echo $testu +../fish -c 'echo $testu' + +../fish -c 'set -U testu 2' +echo $testu +../fish -c 'echo $testu' + +../fish -c 'set -e testu'; +echo Missing: $testu +../fish -c 'echo Missing: $testu' + true diff --git a/tests/test3.out b/tests/test3.out index 5b4e3d112..d6cbdb9c8 100644 --- a/tests/test3.out +++ b/tests/test3.out @@ -14,3 +14,10 @@ Test 13 pass Test 14 pass Test 15 pass Test 16 pass +Testing Universal Startup +1 +1 +2 +2 +Missing: +Missing: