Merge origin/main into better-icons
CI / check (pull_request) Failing after 10s
CI / native (pull_request) Successful in 1m9s

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
SpriteandClaude Sonnet 5.5 committed 2026-11-23 00:48:27 +00:00
commit 3ac96fea35
16 files changed
+503 -18

No files matched your search

+15 -5
View File
@@ -80,16 +80,17 @@ wait_for() {
# can wedge its event queue, after which nothing gets linked.
wait_for '\[default'
LOGS="$XDG_RUNTIME_DIR"
# Two minutes of stereo s16 48 kHz silence as a WAV file (header written by
# hand: no python/sox needed). Reading raw audio from /dev/zero made older
# pw-cat (PipeWire 1.4) exit without creating a stream.
# Two minutes of stereo s16 48 kHz noise as a WAV file (header written by
# hand: no python/sox needed), so the peak meters have a signal; it only
# plays into the private null sinks. Reading raw audio from a device made
# older pw-cat (PipeWire 1.4) exit without creating a stream, so it is a file.
le32() { printf "\\$(printf %03o $(($1 & 255)))\\$(printf %03o $(($1 >> 8 & 255)))\\$(printf %03o $(($1 >> 16 & 255)))\\$(printf %03o $(($1 >> 24 & 255)))"; }
DATA=23040000
{ printf 'RIFF'; le32 $((DATA + 36)); printf 'WAVEfmt '; le32 16
printf '\001\000\002\000'; le32 48000; le32 192000; printf '\004\000\020\000'
printf 'data'; le32 $DATA; head -c $DATA /dev/zero; } > "$LOGS/silence.wav"
printf 'data'; le32 $DATA; head -c $DATA /dev/urandom; } > "$LOGS/noise.wav"
{ pw-play -P '{ application.name = "Test Player" application.icon-name = "applications-multimedia-symbolic" media.name = "Smoke test tone" }' \
"$LOGS/silence.wav"; echo "pw-play exited with $?"; } >"$LOGS/play.log" 2>&1 & PIDS="$PIDS $!"
"$LOGS/noise.wav"; echo "pw-play exited with $?"; } >"$LOGS/play.log" 2>&1 & PIDS="$PIDS $!"
pw-cat --record --raw --rate 48000 --channels 1 --format s16 \
-P '{ application.name = "Test Recorder" application.icon-name = "audio-input-microphone" media.name = "Mic capture" }' \
/dev/null >"$LOGS/record.log" 2>&1 & PIDS="$PIDS $!"
@@ -120,6 +121,15 @@ step 'Test Headphones | .*\[default\]' default test_headphones
STREAM=$("$PROBE" | awk -F: '/Test Player/ {gsub(/ /,"",$1); print $1; exit}')
step 'Test Player | .*-> Test Speakers' move "${STREAM:-0}" test_speakers
# meter <node>: a peak meter on it must see the noise.
meter() {
echo "### meter $1"
"$PROBE" meter "$1" >"$OUT" 2>&1 || { echo "FAIL: no signal on $1's meter"; fail=1; }
grep '^== meter' "$OUT"
}
meter "${STREAM:-0}"
meter test_speakers
if [ "$fail" != 0 ]; then
echo "### diagnostics"
echo "--- pw-play playback:"; cat "$LOGS/play.log"