commit: a69c18fd8c0d31ea4a392f680a89252a69de1173
parent 6c7a8fea8f3ae32209167739cd144fd9084b0b73
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date: Sun, 15 May 2022 16:36:31 +0200
test-bin/id: shellcheck fix
Diffstat:
1 file changed, 12 insertions(+), 0 deletions(-)
diff --git a/test-bin/id b/test-bin/id
@@ -64,10 +64,14 @@ noetc_body() {
set -f
+ # shellcheck disable=SC2086
atf_check -o "inline:$(id -u)\n" -- "${BWRAP:-bwrap}" ${bwrap_args} ../bin/id -u
+ # shellcheck disable=SC2086
atf_check -s exit:1 -e "inline:id: cannot find name for user ID $(id -u)\n" -o "inline:$(id -u)\n" -- "${BWRAP:-bwrap}" ${bwrap_args} ../bin/id -un
+ # shellcheck disable=SC2086
atf_check -o "inline:$(id -g)\n" -- "${BWRAP:-bwrap}" ${bwrap_args} ../bin/id -g
+ # shellcheck disable=SC2086
atf_check -s exit:1 -e "inline:id: cannot find name for group ID $(id -g)\n" -o "inline:$(id -g)\n" -- "${BWRAP:-bwrap}" ${bwrap_args} ../bin/id -gn
}
@@ -80,10 +84,14 @@ nopasswd_body() {
set -f
+ # shellcheck disable=SC2086
atf_check -o "inline:$(id -u)\n" -- "${BWRAP:-bwrap}" ${bwrap_args} ../bin/id -u
+ # shellcheck disable=SC2086
atf_check -s exit:1 -e "inline:id: cannot find name for user ID $(id -u)\n" -o "inline:$(id -u)\n" -- "${BWRAP:-bwrap}" ${bwrap_args} ../bin/id -un
+ # shellcheck disable=SC2086
atf_check -o "inline:$(id -g)\n" -- "${BWRAP:-bwrap}" ${bwrap_args} ../bin/id -g
+ # shellcheck disable=SC2086
atf_check -o "inline:$(id -gn)\n" -- "${BWRAP:-bwrap}" ${bwrap_args} ../bin/id -gn
}
@@ -96,10 +104,14 @@ nogroup_body() {
set -f
+ # shellcheck disable=SC2086
atf_check -o "inline:$(id -u)\n" -- "${BWRAP:-bwrap}" ${bwrap_args} ../bin/id -u
+ # shellcheck disable=SC2086
atf_check -o "inline:$(id -un)\n" -- "${BWRAP:-bwrap}" ${bwrap_args} ../bin/id -un
+ # shellcheck disable=SC2086
atf_check -o "inline:$(id -g)\n" -- "${BWRAP:-bwrap}" ${bwrap_args} ../bin/id -g
+ # shellcheck disable=SC2086
atf_check -s exit:1 -e "inline:id: cannot find name for group ID $(id -g)\n" -o "inline:$(id -g)\n" -- "${BWRAP:-bwrap}" ${bwrap_args} ../bin/id -gn
}