diff options
| author | 2023-03-20 15:08:33 +0000 | |
|---|---|---|
| committer | 2023-03-20 15:08:33 +0000 | |
| commit | dc732a85e1b781fafa45ca630723d6173246b280 (patch) | |
| tree | ad8d8a165b3977b8217b27392c3cd5855b79a0be /api/api_test.go | |
| parent | a55730c9bc6287235374a2461e0a36a60f64a5e2 (diff) | |
Don't crash on transition DOZE_SUSPEND_TRIGGERS => DOZE_PULSE_DONE
This transition can happen with the following sequence of events:
- Heads up notification arrives during doze_aod or doze, pulse
begins (DOZE_REQUEST_PULSE, DOZE_PULSING)
- While pulsing, car mode begins (DOZE_SUSPEND_TRIGGERS)
- Heads up notification stops showing (DOZE_PULSE_DONE)
If the device is in DOZE_SUSPEND_TRIGGERS, don't send DOZE_PULSE_DONE
to DozeMachine.Parts. DOZE_SUSPEND_TRIGGERS means the device
has already ended the pulsing UI.
Test: atest DozeMachineTest
Test: manually force car mode to start after DOZE_PULSING and see that
the device won't crash on pulse-done
Fixes: 262346136
Change-Id: Icc16b8a16af1fd266a2afcfdbe6e1121ef788d65
Diffstat (limited to 'api/api_test.go')
0 files changed, 0 insertions, 0 deletions