CEC: Add VTS test to check is connected am: b75639ca66 am: de3c301a52 am: ae30530f38

Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/1584905

Change-Id: Ie578de3bba8ef2069a4441010aa9f0eed1bb56e1
This commit is contained in:
Shraddha Basantwani 2021-03-30 12:43:22 +00:00 committed by Automerger Merge Worker
commit 586fe14899

View file

@ -150,3 +150,14 @@ TEST_P(HdmiCecTest, EnableAudioReturnChannel) {
} }
} }
} }
TEST_P(HdmiCecTest, IsConnected) {
hidl_vec<HdmiPortInfo> ports;
Return<void> ret =
hdmiCec->getPortInfo([&ports](hidl_vec<HdmiPortInfo> list) { ports = list; });
EXPECT_TRUE(ret.isOk());
for (size_t i = 0; i < ports.size(); ++i) {
Return<bool> ret = hdmiCec->isConnected(ports[i].portId);
EXPECT_TRUE(ret.isOk());
}
}