diff options
author | Pádraig Brady <P@draigBrady.com> | 2013-10-06 17:26:51 +0100 |
---|---|---|
committer | Pádraig Brady <P@draigBrady.com> | 2013-10-06 17:59:44 +0100 |
commit | 0c1d7917f19b4865544ab9f1b13dfcdfd4e65275 (patch) | |
tree | dd83d3ea254ca12948e4ce248676f76e3bef8934 /tests/misc/mktemp.pl | |
parent | 8e67c2dec1a595619d540bc3e52c2dfcf61a63a3 (diff) | |
download | coreutils-0c1d7917f19b4865544ab9f1b13dfcdfd4e65275.tar.xz |
mktemp: with --quiet, only suppress I/O errors
The reason for having a --quiet option is to
suppress only some subset of possible errors.
The most useful separation here is with usage/internal errors,
and errors due to file creation etc. (i.e. I/O errors).
* src/mktemp.c (main): Match the --help and info docs and
only suppress the file/dir creation error messages.
* tests/misc/mktemp.pl: Adjust accordingly.
Diffstat (limited to 'tests/misc/mktemp.pl')
-rwxr-xr-x | tests/misc/mktemp.pl | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/tests/misc/mktemp.pl b/tests/misc/mktemp.pl index b15b6694b..d47371c14 100755 --- a/tests/misc/mktemp.pl +++ b/tests/misc/mktemp.pl @@ -55,14 +55,12 @@ my @Tests = ( # test-name, [option, option, ...] {OUT=>"expected-output"} # - ['too-many', 'a b', + ['too-many', '-q a b', {ERR=>"$prog: too many templates\n" . "Try '$prog --help' for more information.\n"}, {EXIT => 1} ], - ['too-many-q', '-q a b', {EXIT => 1} ], - ['too-few-x', 'foo.XX', {EXIT => 1}, + ['too-few-x', '-q foo.XX', {EXIT => 1}, {ERR=>"$prog: too few X's in template 'foo.XX'\n"}], - ['too-few-xq', '-q foo.XX', {EXIT => 1} ], ['1f', 'bar.XXXX', {OUT => "bar.ZZZZ\n"}, {OUT_SUBST => 's,\.....$,.ZZZZ,'}, @@ -148,11 +146,9 @@ my @Tests = ['suffix6f', 'aXXXX/b', {EXIT=>1}, {ERR=>"$prog: invalid suffix '/b', contains directory separator\n"}], - ['suffix6f-q', '-q aXXXX/b', {EXIT=>1}], ['suffix7f', '--suffix= aXXXXb', {EXIT=>1}, {ERR=>"$prog: with --suffix, template 'aXXXXb' must end in X\n"}], - ['suffix7f-q', '-q --suffix= aXXXXb', {EXIT=>1}], ['suffix7d', '-d --suffix=aXXXXb ""', {EXIT=>1}, {ERR=>"$prog: with --suffix, template '' must end in X\n"}], |