logo

utils-std

Collection of commonly available Unix tools
commit: 22434f313fe9642c33a9d472a85396a87e5a74a2
parent f232517194f2abba93ad78c148e068bdf6d6c54a
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date:   Thu, 13 Jun 2024 19:32:37 +0200

test-cmd/chmod: Restore invalid mode test

Diffstat:

Mtest-cmd/chmod.sh4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/test-cmd/chmod.sh b/test-cmd/chmod.sh @@ -3,7 +3,7 @@ # SPDX-License-Identifier: MPL-2.0 target="$(dirname "$0")/../cmd/chmod" -plans=6 +plans=7 . "$(dirname "$0")/tap.sh" tmpfile="${TMPDIR-/tmp}/test_chmod_$(date +%s)" @@ -25,6 +25,6 @@ t '0444' "-v 0444 $tmpfile" "chmod: Permissions changed from 00000/---------- to t '0777' "-v 0777 $tmpfile" "chmod: Permissions changed from 00444/-r--r--r-- to 00777/-rwxrwxrwx for '${tmpfile}' " -# atf_check -s not-exit:0 -e "inline:chmod: Failed parsing mode '0888': contains digit outside of [0-7]\n" ../cmd/chmod -v 0888 "${TMPDIR}/chmod_octal" +t --exit=1 'invalid 0888' "-v 0888 $tmpfile" "chmod: Failed parsing mode '0888': contains digit outside of [0-7]"$'\n' rm "$tmpfile" || exit 1