Skip to content

Commit

Permalink
volume-basic-test.sh: don't skip "playback volume" controls
Browse files Browse the repository at this point in the history
Looking for "PGA" is not enough.

Signed-off-by: Marc Herbert <[email protected]>
  • Loading branch information
marc-hb committed Jun 27, 2023
1 parent 923d71f commit 4107881
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion test-case/volume-basic-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,10 @@ sleep 1
[[ ! $(pidof aplay) ]] && die "aplay process is terminated too early"

sofcard=${SOFCARD:-0}
readarray -t pgalist < <(amixer -c"$sofcard" controls | awk -Fname= 'toupper($2) ~ /PGA/ { print $2 }')
# This (1) provides some logging (2) avoids skip_test if amixer fails
amixer -c"$sofcard" controls
readarray -t pgalist < <(amixer -c"$sofcard" controls |
awk -Fname= 'tolower($2) ~ /pga|playback.*volume/ { print $2 }')
dlogi "pgalist number = ${#pgalist[@]}"
[[ ${#pgalist[@]} -ne 0 ]] || skip_test "No PGA control is available"

Expand Down

0 comments on commit 4107881

Please sign in to comment.