AudioDeviceVolumeManagerTest: harden waiting for vol change
Implement test utility class, SleepAssertIntEquals, that checks
that an expected int value is returned by a lambda (the
functionality under test). That check can be performed a number
of times at a given period, for a given max duration, after which
the test asserts for failure.
Use this utility class for giving AudioDeviceVolumeManager
more time to respond to device volume changes.
MUST_SLEEP (similar to Varztester but can't import it here)
Bug: 271473257
Test: atest android.media.audio.cts.AudioDeviceVolumeManagerTest#testSetGetVolume
Change-Id: I6ccfc817c3c3885fd4aecfb49cf1c3984320aa2e
4 files changed