diff options
author | paulye <paulye@google.com> | 2019-02-25 15:19:08 -0800 |
---|---|---|
committer | paulye <paulye@google.com> | 2019-02-26 15:34:34 -0800 |
commit | 7042a1aa9da54eb2274fff0aa3f60c446d48bb48 (patch) | |
tree | 6227db51942820c57b98fd33d0dc9aa2bda0b674 /radio/1.4 | |
parent | 3cdb31ee57c06963af77000faf8aaf4bbd9737aa (diff) | |
download | platform_hardware_interfaces-7042a1aa9da54eb2274fff0aa3f60c446d48bb48.tar.gz platform_hardware_interfaces-7042a1aa9da54eb2274fff0aa3f60c446d48bb48.tar.bz2 platform_hardware_interfaces-7042a1aa9da54eb2274fff0aa3f60c446d48bb48.zip |
Add vts for getSignalStrength_1_4
Test: VTS
Bug: 124013054
Change-Id: Ia23391970d2c333b128ab8d2990d231e62748789
Diffstat (limited to 'radio/1.4')
-rw-r--r-- | radio/1.4/vts/functional/radio_hidl_hal_api.cpp | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/radio/1.4/vts/functional/radio_hidl_hal_api.cpp b/radio/1.4/vts/functional/radio_hidl_hal_api.cpp index 52eb27779e..c395df64c3 100644 --- a/radio/1.4/vts/functional/radio_hidl_hal_api.cpp +++ b/radio/1.4/vts/functional/radio_hidl_hal_api.cpp @@ -439,6 +439,26 @@ TEST_F(RadioHidlTest_v1_4, startNetworkScan_GoodRequest2) { {RadioError::NONE, RadioError::INVALID_ARGUMENTS})); } } + +/* + * Test IRadio.getSignalStrength_1_4() for the response returned. + */ +TEST_F(RadioHidlTest_v1_4, getSignalStrength_1_4) { + serial = GetRandomSerialNumber(); + + radio_v1_4->getSignalStrength_1_4(serial); + EXPECT_EQ(std::cv_status::no_timeout, wait()); + EXPECT_EQ(RadioResponseType::SOLICITED, radioRsp_v1_4->rspInfo.type); + EXPECT_EQ(serial, radioRsp_v1_4->rspInfo.serial); + + if (cardStatus.base.base.cardState == CardState::ABSENT) { + EXPECT_EQ(RadioError::NONE, radioRsp_v1_4->rspInfo.error); + } else if (cardStatus.base.base.cardState == CardState::PRESENT) { + ASSERT_TRUE(CheckAnyOfErrors(radioRsp_v1_4->rspInfo.error, + {RadioError::NONE, RadioError::RADIO_NOT_AVAILABLE})); + } +} + /* * Test IRadio.setupDataCall_1_4() for the response returned. */ |