Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e8957a35 authored by Kevin Rocard's avatar Kevin Rocard
Browse files

Audio VTS: Always check for Result::isOk()



A test was not checking for the Result::isOk() resulting
in an assert being triggered in HIDL code if the HAL crashed.

Test: (sleep 0.3; adb shell pkill audio) &
      adb shell /data/nativetest64/VtsHalAudioV4_0TargetTest/VtsHalAudioV4_0TargetTest
      # Test finishes in failure but does not crash
Signed-off-by: default avatarKevin Rocard <krocard@google.com>

Change-Id: I97a6213fe82a5e9a6eb333dc1dc2476102610b58
parent 391eb588
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1402,6 +1402,7 @@ TEST_F(AudioPrimaryHidlTest, setBtHfpVolume) {
        "Make sure setBtHfpVolume is either not supported or "
        "only succeed if volume is in [0,1]");
    auto ret = device->setBtHfpVolume(0.0);
    ASSERT_TRUE(ret.isOk());
    if (ret == Result::NOT_SUPPORTED) {
        doc::partialTest("setBtHfpVolume is not supported");
        return;