tests/int: remove bogus $status checks

Commands that are not run via "run" helper (cat, mkdir, __runc)
do not set $status, so it makes no sense to check it.

Fixes: 94505a04, ed548376
Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
This commit is contained in:
Kir Kolyshkin
2025-10-16 16:31:01 -07:00
parent 693a471af8
commit b3a9f423b9
2 changed files with 0 additions and 5 deletions
-4
View File
@@ -48,12 +48,10 @@ function teardown() {
# Use sub-cgroup to ensure that exec process has been killed
test_pidfd_cgroup_path=$(get_cgroup_path "pids")
mkdir "${test_pidfd_cgroup_path}/exec_pidfd"
[ "$status" -eq 0 ]
setup_pidfd_kill "SIGKILL"
__runc exec -d --cgroup "pids:exec_pidfd" --pid-file "exec_pid.txt" --pidfd-socket "${PIDFD_SOCKET}" test_pidfd sleep 1d
[ "$status" -eq 0 ]
exec_pid=$(cat exec_pid.txt)
exec_pid_in_cgroup=$(cat "${test_pidfd_cgroup_path}/exec_pidfd/cgroup.procs")
@@ -79,12 +77,10 @@ function teardown() {
# Use sub-cgroup to ensure that exec process has been killed
test_pidfd_cgroup_path=$(get_cgroup_path "pids")
mkdir "${test_pidfd_cgroup_path}/exec_pidfd"
[ "$status" -eq 0 ]
setup_pidfd_kill "SIGKILL"
__runc exec -d --cgroup "exec_pidfd" --pid-file "exec_pid.txt" --pidfd-socket "${PIDFD_SOCKET}" test_pidfd sleep 1d
[ "$status" -eq 0 ]
exec_pid=$(cat exec_pid.txt)
exec_pid_in_cgroup=$(cat "${test_pidfd_cgroup_path}/exec_pidfd/cgroup.procs")
-1
View File
@@ -320,7 +320,6 @@ EOF
}
}
EOF
[ "$status" -eq 0 ]
runc update -r "$BATS_RUN_TMPDIR"/runc-cgroups-integration-test.json test_update
[ "$status" -eq 0 ]