diff options
author | Pádraig Brady <P@draigBrady.com> | 2014-06-03 10:50:09 +0100 |
---|---|---|
committer | Pádraig Brady <P@draigBrady.com> | 2014-06-03 18:39:57 +0100 |
commit | 9a6a486e6503520fd2581f2d3356b7149f1b225d (patch) | |
tree | 8752754ae8780de8ceb4d2ab1113d8b74faef77c /src/true.c | |
parent | 1239ac573df0a699d6999aed23caaf4a0eb099df (diff) | |
download | coreutils-9a6a486e6503520fd2581f2d3356b7149f1b225d.tar.gz |
tests: consolidate tests for true and false
* src/true.c (main): Add a comment about the possibility
of true returning EXIT_FAILURE due to write failure.
* tests/misc/false-status.sh: Fix so we're testing
the tool and not the shell builtin. Add a case for true(1).
* tests/misc/help-version.sh: Skip /dev/full test
for true as well as false since the exit status is tested separately.
Also remove the iterations for different LC_MESSAGES, as this was only
applied for false(1). Translations are not honored in the test dir
and so would need separate handling in any case.
Diffstat (limited to 'src/true.c')
-rw-r--r-- | src/true.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/true.c b/src/true.c index 219f98c86..8a1c4f920 100644 --- a/src/true.c +++ b/src/true.c @@ -64,6 +64,8 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); + /* Note true(1) will return EXIT_FAILURE in the + edge case where writes fail with GNU specific options. */ atexit (close_stdout); if (STREQ (argv[1], "--help")) |