| History log of /src/tests/bin/sh/t_redir.sh |
| Revision | | Date | Author | Comments |
| 1.14 |
| 21-Nov-2021 |
kre | Deal with a lot more pipes into atf_check missed last time.
|
| 1.13 |
| 16-Nov-2021 |
kre | Fix a test that has been (unnoticed) failing ever since printf(1) was changed to exit(1) when it detects a write error to stdout.
Running printf with stdout closed is guaranteed to generate such a condition.
Until the previous commit, while the test case was actually failing (stderr was expected to be empty. and was not) this was unnoticed. We don't want the output (obviously), we also don't want the error message, so just direct the latter to /dev/null.
|
| 1.12 |
| 16-Nov-2021 |
kre | Correct a systematic atf_check usage error. One must not pipe into atf_check and simply expect it to work - the shell is permitted to, and our shell currently does, run all commands in a pipeline in subshell environments - when atf_check attempts to exit to indicate failure, it only exits from that subshell, and the rest of the test continues, usually to indicate success
Instead, when it is necessary (or just convenient) to pipe into atf_check check the exit status of the pipeline (if atf_check is not last, which it would usually be, then we would need the pipefail option set - there are currently no such cases), and explicitly fail if atf_check did not exit(0).
|
| 1.11 |
| 19-May-2021 |
kre | Handle the (very) recent change to printf(1) - when writing to a closed stdout printf(1) now issues an error message, hence stderr in such cases should not be empty, rather than should be empty. Adapt to that.
|
| 1.10 |
| 27-Nov-2018 |
kre | branches: 1.10.6;
Add a new test case to test <> (open for input & output), includion a test to make sure that the file doesn't get truncated.
Add new subtests to the "incorrect redirections" test case, to validate correct behaviour of the shell when redirections fail in various scenarios, including when the redirect is the whole command.
More along these lines are really needed, but this is better than nothing.
All the added tests pass on the /bin/sh currently in netbsd HEAD.
|
| 1.9 |
| 14-May-2016 |
kre | branches: 1.9.14; 1.9.16;
Add another test for the 48875 fix fallout...
|
| 1.8 |
| 11-May-2016 |
kre | Add a test for fd redirections on functions in loops (the etcupdate issue) and also fix a quoting bug which was causing a test to fail, though ATF was ignoring (an ATF bug to be investigated later.)
OK christos@
|
| 1.7 |
| 09-May-2016 |
kre | PR bin/48875 PR bin/51123 This adds tests more that verify fide descriptor redirection works correctly (including that the bugs reported in those PRs are fixed.) Note that the tests for 48875 are slow, so one of the new test cases ends up running > 25 seconds (just doing sleeps) - each individual test is just a few seconds, but there are several of them.
OK christos@
|
| 1.6 |
| 02-May-2016 |
christos | More redirect tests, in particular, tests for redirects to/from file descriptors outside the 0..9 range, and complex fd reassignments. Also test that the shell can cope with the value of ulimit -n changing (downwards, up is harmless) (Freom kre@)
|
| 1.5 |
| 27-Mar-2016 |
christos | Avoid relying on the test shell correctly implementing $(( )) in order for some of the redirect tests to terminate. (from kre@)
|
| 1.4 |
| 08-Mar-2016 |
christos | Added more test cases, more exhaustive testing. (from kre)
|
| 1.3 |
| 01-Mar-2016 |
christos | Improved handling of TEST_SH so that it is possible to define it to the name of a shell, plus options that shell needs to run it in the correct mode to be tested: eg: TEST_SH='bash -o posix' Also finished the implementation of tests of "set -n" now that the NetBSD shell supports that as it should. (from kre)
|
| 1.2 |
| 23-Feb-2016 |
christos | Add new redirection test, from kre
|
| 1.1 |
| 22-Feb-2016 |
christos | Add new test
|
| 1.9.16.1 |
| 10-Jun-2019 |
christos | Sync with HEAD
|
| 1.9.14.1 |
| 26-Dec-2018 |
pgoyette | Sync with HEAD, resolve a few conflicts
|
| 1.10.6.1 |
| 31-May-2021 |
cjep | sync with head
|