From 4e0f86b387e003c5d2b466f79b200a7b488d5793 Mon Sep 17 00:00:00 2001 From: Srikanth Muppandam Date: Tue, 7 Apr 2026 22:38:39 +0530 Subject: [PATCH 1/4] The Audio_Playback testcase defines a cleanup() helper that is invoked indirectly via trap on EXIT/INT/TERM. ShellCheck reports SC2317 on the pkill call because it cannot see the trap-based invocation path, but the function is valid and part of the existing cleanup flow. Add a targeted SC2317 suppression on cleanup() without changing runtime behavior. Signed-off-by: Srikanth Muppandam --- Runner/suites/Multimedia/GSTreamer/Audio/Audio_Playback/run.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/Runner/suites/Multimedia/GSTreamer/Audio/Audio_Playback/run.sh b/Runner/suites/Multimedia/GSTreamer/Audio/Audio_Playback/run.sh index 69be70c8..48c0481d 100755 --- a/Runner/suites/Multimedia/GSTreamer/Audio/Audio_Playback/run.sh +++ b/Runner/suites/Multimedia/GSTreamer/Audio/Audio_Playback/run.sh @@ -96,6 +96,7 @@ if [ -n "$channels" ]; then channelsUser="1" fi +# shellcheck disable=SC2317 # Invoked indirectly via trap. cleanup() { pkill -x gst-launch-1.0 >/dev/null 2>&1 || true } From 2fde3ea4b80627208ade2726088d0422ef135350 Mon Sep 17 00:00:00 2001 From: Srikanth Muppandam Date: Tue, 7 Apr 2026 22:39:06 +0530 Subject: [PATCH 2/4] Libcamera_cam printed artifact locations after the final PASS/FAIL exit path, making that block unreachable and triggering ShellCheck SC2317. Move the artifact summary logging above the final verdict so the logs are actually emitted while preserving the existing PASS/FAIL behavior and result-file flow. Signed-off-by: Srikanth Muppandam --- .../suites/Multimedia/Camera/Libcamera_cam/run.sh | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/Runner/suites/Multimedia/Camera/Libcamera_cam/run.sh b/Runner/suites/Multimedia/Camera/Libcamera_cam/run.sh index 5a746700..dd8e5bb7 100755 --- a/Runner/suites/Multimedia/Camera/Libcamera_cam/run.sh +++ b/Runner/suites/Multimedia/Camera/Libcamera_cam/run.sh @@ -284,6 +284,13 @@ else fi log_info "Summary file: $OUT_DIR/summary.txt" +# ---------- Artifacts ---------- +log_info "Artifacts under: $OUT_DIR/" +for IDX in $INDICES; do + CAM_DIR="${OUT_DIR%/}/cam${IDX}" + log_info " - $CAM_DIR/" +done + # ---------- Final verdict ---------- if [ "$OVERALL_PASS" -eq 1 ] && [ $ANY_RC_NONZERO -eq 0 ]; then echo "$TESTNAME PASS" > "$RES_FILE" @@ -294,10 +301,3 @@ else log_fail "$TESTNAME FAIL" exit 1 fi - -# ---------- Artifacts ---------- -log_info "Artifacts under: $OUT_DIR/" -for IDX in $INDICES; do - CAM_DIR="${OUT_DIR%/}/cam${IDX}" - log_info " - $CAM_DIR/" -done From 5540e829ecce094c766c81601a20cf981f43495c Mon Sep 17 00:00:00 2001 From: Srikanth Muppandam Date: Tue, 7 Apr 2026 22:39:28 +0530 Subject: [PATCH 3/4] fastrpc_test keeps a small log_debug() helper for optional verbose debug use, but ShellCheck flags it with SC2317 because it is not exercised in the normal visible path. Add a narrow SC2317 suppression for the helper without changing the current test flow or runtime behavior. Signed-off-by: Srikanth Muppandam --- Runner/suites/Multimedia/CDSP/fastrpc_test/run.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/Runner/suites/Multimedia/CDSP/fastrpc_test/run.sh b/Runner/suites/Multimedia/CDSP/fastrpc_test/run.sh index 4546e45f..e5be43eb 100755 --- a/Runner/suites/Multimedia/CDSP/fastrpc_test/run.sh +++ b/Runner/suites/Multimedia/CDSP/fastrpc_test/run.sh @@ -119,6 +119,7 @@ cd "$test_path" || { } # -------------------- Helpers -------------------- +# shellcheck disable=SC2317 # Helper kept for optional debug use. log_debug() { [ "$VERBOSE" -eq 1 ] && log_info "[debug] $*"; } cmd_to_string() { From 9969c6f849e076525b5ecdfa8216d86e977e18cc Mon Sep 17 00:00:00 2001 From: Srikanth Muppandam Date: Tue, 7 Apr 2026 22:39:52 +0530 Subject: [PATCH 4/4] Video_V4L2_Runner already exits from all branches of the final overall result block, so the trailing exit is dead code and triggers ShellCheck SC2317. Remove the unreachable exit without changing the testcase result flow, logging, or exit semantics. Signed-off-by: Srikanth Muppandam --- Runner/suites/Multimedia/Video/Video_V4L2_Runner/run.sh | 2 -- 1 file changed, 2 deletions(-) diff --git a/Runner/suites/Multimedia/Video/Video_V4L2_Runner/run.sh b/Runner/suites/Multimedia/Video/Video_V4L2_Runner/run.sh index 4ec7e285..72fa5bdc 100755 --- a/Runner/suites/Multimedia/Video/Video_V4L2_Runner/run.sh +++ b/Runner/suites/Multimedia/Video/Video_V4L2_Runner/run.sh @@ -1386,5 +1386,3 @@ else printf '%s\n' "$TESTNAME FAIL" >"$RES_FILE" exit 1 fi - -exit "$suite_rc"