diff options
author | stefanf <stefanf@FreeBSD.org> | 2008-03-22 14:07:49 +0000 |
---|---|---|
committer | stefanf <stefanf@FreeBSD.org> | 2008-03-22 14:07:49 +0000 |
commit | 0f834356e362ad22fd5789d0ebc7a086c303aec1 (patch) | |
tree | 3cda960647dc89dba9a151c41e41de939889e8f8 | |
parent | d52b1cf43ee9e8d06f32d2bd3eb47d345b42e0ff (diff) | |
download | FreeBSD-src-0f834356e362ad22fd5789d0ebc7a086c303aec1.zip FreeBSD-src-0f834356e362ad22fd5789d0ebc7a086c303aec1.tar.gz |
Add a test case for options.c revision 1.26.
-rw-r--r-- | tools/regression/bin/sh/builtins/getopts1.0 | 12 | ||||
-rw-r--r-- | tools/regression/bin/sh/builtins/getopts1.0.stdout | 3 |
2 files changed, 15 insertions, 0 deletions
diff --git a/tools/regression/bin/sh/builtins/getopts1.0 b/tools/regression/bin/sh/builtins/getopts1.0 new file mode 100644 index 0000000..ecb509f --- /dev/null +++ b/tools/regression/bin/sh/builtins/getopts1.0 @@ -0,0 +1,12 @@ +# $FreeBSD$ +set -- -abc +getopts "ab:" OPTION +echo ${OPTION} + +set -- -ab +getopts "ab:" OPTION +echo ${OPTION} + +shift 1 +getopts "ab:" OPTION +echo ${OPTION} diff --git a/tools/regression/bin/sh/builtins/getopts1.0.stdout b/tools/regression/bin/sh/builtins/getopts1.0.stdout new file mode 100644 index 0000000..bf8e71e --- /dev/null +++ b/tools/regression/bin/sh/builtins/getopts1.0.stdout @@ -0,0 +1,3 @@ +a +a +? |