Skip to content

Commit

Permalink
apause.exp: promote unexpected "PAUSE" feedback from warning to failure
Browse files Browse the repository at this point in the history
Experience with thesofproject/linux#5109 shows
that this warning never seems harmless: the test ends up timing out and
failing anyway.

So, better failing fast for clearer and better logs.

Also increase the log level of press_space() to avoid state confusion.

Signed-off-by: Marc Herbert <[email protected]>
  • Loading branch information
marc-hb committed Aug 1, 2024
1 parent e5f9248 commit d25ac5b
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions case-lib/apause.exp
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ proc rel_time_ms {} {

proc press_space {} {
global last_space_time
log 2 "Pressing SPACE"
log 1 "Pressing SPACE"
send " "
set last_space_time [rel_time_ms]
log 3 "last_space_time set to $last_space_time"
Expand Down Expand Up @@ -237,12 +237,8 @@ expect {

{=== PAUSE ===} {
if {$state != "pause_requested"} {
# TODO: upgrade this to an ERROR if we want to fix pause bugs like
# https://github.com/thesofproject/linux/issues/5109
# As of July 2024, pause is rather being disabled:
# https://github.com/thesofproject/linux/pull/5041
log 0 "WARNING: received == PAUSE == while in state $state! Ignoring."
exp_continue
log 0 "ERROR: received == PAUSE == while in state $state!"
exit 1
}

set state paused
Expand Down

0 comments on commit d25ac5b

Please sign in to comment.