2017-08-05 04:36:51 +08:00
|
|
|
|
|
|
|
####################
|
|
|
|
# Test scoping rules for functions
|
2005-09-20 21:31:55 +08:00
|
|
|
Test 1 pass
|
|
|
|
Test 2 pass
|
|
|
|
Test 3 pass
|
2006-06-05 21:31:33 +08:00
|
|
|
Test 4 pass
|
2012-06-19 01:20:40 +08:00
|
|
|
Test 5 pass
|
|
|
|
Test 6 pass
|
|
|
|
Test 7 pass
|
|
|
|
Test 8 pass
|
|
|
|
Test 9 pass
|
|
|
|
Test 10 pass
|
|
|
|
Test 11 pass
|
|
|
|
Test 12 pass
|
|
|
|
Test 13 pass
|
|
|
|
Test 14 pass
|
|
|
|
Test 15 pass
|
|
|
|
Test 16 pass
|
|
|
|
Test 17 pass
|
|
|
|
Test 18 pass
|
|
|
|
Test 19 pass
|
|
|
|
Test 20 pass
|
|
|
|
Test 21 pass
|
|
|
|
Test 22 pass
|
2017-08-05 04:36:51 +08:00
|
|
|
|
|
|
|
####################
|
2017-07-25 02:42:54 +08:00
|
|
|
# Verify subcommand statuses
|
2013-02-01 07:57:08 +08:00
|
|
|
1 0 1
|
2017-08-05 04:36:51 +08:00
|
|
|
|
|
|
|
####################
|
2017-07-25 02:42:54 +08:00
|
|
|
# Verify that set passes through exit status, except when passed -n or -q or -e
|
2013-02-01 07:57:08 +08:00
|
|
|
1 1
|
|
|
|
2 0
|
|
|
|
3 0
|
|
|
|
4 0
|
|
|
|
5 0
|
|
|
|
6 0
|
2018-04-01 11:21:22 +08:00
|
|
|
7 4
|
2013-02-01 07:57:08 +08:00
|
|
|
8 0
|
2018-12-16 14:05:19 +08:00
|
|
|
9 2
|
2013-02-01 07:57:08 +08:00
|
|
|
10 0 A
|
|
|
|
11 1 B
|
2017-08-05 04:36:51 +08:00
|
|
|
|
|
|
|
####################
|
|
|
|
# Verify set -ql behavior (#2502)
|
2015-10-24 06:15:39 +08:00
|
|
|
Pass
|