NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: misc/59155 (bin/sh/t_input:nul_elimination, possibly other sh tests, require root for silly reasons)
The following reply was made to PR misc/59155; it has been noted by GNATS.
From: Robert Elz <kre%munnari.OZ.AU@localhost>
To: gnats-bugs%netbsd.org@localhost
Cc:
Subject: Re: misc/59155 (bin/sh/t_input:nul_elimination, possibly other sh tests, require root for silly reasons)
Date: Mon, 10 Mar 2025 04:14:57 +0700
Jason, can you demonstrate how you ran the test, along with
permissions, owners, etc, on any directories you consider
relevant.
It would also be mildly interesting to understand your interest
in running a test which is currently broken (by sh updates) and
which I have yet to take the time to work out what to do about.
Though I guess that perhaps it is still intended to work in -10.
(Most probably the whole test will simply be dropped, and replaced
by one which verifies that \0 chars are treated as errors, but
that test took quite a bit of effort to generate to make sure
representatives of just about all the weird places a \0 might
appear, and make sure they were all being ignored, that I kind
of hate to lose it!)
| Normally, atf-run creates a temporary directory which the test can
| write into.
Yes.
| mkdir /tmp/test
| cd /tmp/test
| /usr/tests/bin/sh/t_input nul_elimination
That would be an ugly way to run any ATF test.
| It would be nice if there were a way to ask atf-run to run a single
| test case by name, but we don't have that as far as I know.
You mean like:
jacaranda$ atf-run t_input:nul_elimination | atf-report
Tests root: /home/kre/src/sh-tests
t_input (1/1): 1 test cases
nul_elimination: [2.521333s] Failed: Test case was expecting a failure but none were raised
[2.521638s]
Failed test cases:
t_input:nul_elimination
Summary for 1 test programs:
0 passed test cases.
1 failed test cases.
0 expected failed test cases.
0 skipped test cases.
jacaranda$ TEST_SH=~/src/shells/sh-current/sh atf-run t_input:nul_elimination | atf-report
Tests root: /home/kre/src/sh-tests
t_input (1/1): 1 test cases
nul_elimination: [0.078432s] Expected failure: nuls are now errors, not ignored, revisit later: atf-check failed; see the output of the test for details
[0.078789s]
Test cases for known bugs:
t_input:nul_elimination: nuls are now errors, not ignored, revisit later: atf-check failed;
see the output of the test for details
Summary for 1 test programs:
0 passed test cases.
0 failed test cases.
1 expected failed test cases.
0 skipped test cases.
The first of those used my /bin/sh which is kind of ancient (pre 10
branch), and so failed, because it failed to fail, the second used
the same sh as is /bin/sh in HEAD, and so successfully failed as expected.
kre
Home |
Main Index |
Thread Index |
Old Index