Add fix vts fail when configureMonitorEvent
[Description] VTS StartFilterInDemux failed when configureMonitorEvent is called [Root Cause] Scrambling status event is not notified when configureMonitorEvent is called so test case failed. [Solution] Scrambling status event is not notified because of no input data. Add input setting and check event notified or not after data is input. Test: Manual bug: 288193021 Change-Id: If5875d064fd67b72f8299205a5e35b1a2bd61934
This commit is contained in:
parent
a343d0cf0c
commit
b79cbf50f1
3 changed files with 17 additions and 6 deletions
|
@ -306,12 +306,6 @@ AssertionResult FilterTests::configureMonitorEvent(uint64_t filterId, uint32_t m
|
||||||
android::hardware::tv::tuner::V1_1::IFilter::castFrom(mFilters[filterId]);
|
android::hardware::tv::tuner::V1_1::IFilter::castFrom(mFilters[filterId]);
|
||||||
if (filter_v1_1 != NULL) {
|
if (filter_v1_1 != NULL) {
|
||||||
status = filter_v1_1->configureMonitorEvent(monitorEventTypes);
|
status = filter_v1_1->configureMonitorEvent(monitorEventTypes);
|
||||||
if (monitorEventTypes & DemuxFilterMonitorEventType::SCRAMBLING_STATUS) {
|
|
||||||
mFilterCallbacks[filterId]->testFilterScramblingEvent();
|
|
||||||
}
|
|
||||||
if (monitorEventTypes & DemuxFilterMonitorEventType::IP_CID_CHANGE) {
|
|
||||||
mFilterCallbacks[filterId]->testFilterIpCidEvent();
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
ALOGW("[vts] Can't cast IFilter into v1_1.");
|
ALOGW("[vts] Can't cast IFilter into v1_1.");
|
||||||
return failure();
|
return failure();
|
||||||
|
@ -319,6 +313,17 @@ AssertionResult FilterTests::configureMonitorEvent(uint64_t filterId, uint32_t m
|
||||||
return AssertionResult(status == Result::SUCCESS);
|
return AssertionResult(status == Result::SUCCESS);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
AssertionResult FilterTests::testMonitorEvent(uint64_t filterId, uint32_t monitorEventTypes) {
|
||||||
|
EXPECT_TRUE(mFilterCallbacks[filterId]) << "Test with getNewlyOpenedFilterId first.";
|
||||||
|
if (monitorEventTypes & DemuxFilterMonitorEventType::SCRAMBLING_STATUS) {
|
||||||
|
mFilterCallbacks[filterId]->testFilterScramblingEvent();
|
||||||
|
}
|
||||||
|
if (monitorEventTypes & DemuxFilterMonitorEventType::IP_CID_CHANGE) {
|
||||||
|
mFilterCallbacks[filterId]->testFilterIpCidEvent();
|
||||||
|
}
|
||||||
|
return AssertionResult(true);
|
||||||
|
}
|
||||||
|
|
||||||
AssertionResult FilterTests::startIdTest(uint64_t filterId) {
|
AssertionResult FilterTests::startIdTest(uint64_t filterId) {
|
||||||
EXPECT_TRUE(mFilterCallbacks[filterId]) << "Test with getNewlyOpenedFilterId first.";
|
EXPECT_TRUE(mFilterCallbacks[filterId]) << "Test with getNewlyOpenedFilterId first.";
|
||||||
mFilterCallbacks[filterId]->testStartIdAfterReconfigure();
|
mFilterCallbacks[filterId]->testStartIdAfterReconfigure();
|
||||||
|
|
|
@ -162,6 +162,7 @@ class FilterTests {
|
||||||
AssertionResult configAvFilterStreamType(AvStreamType type, uint64_t filterId);
|
AssertionResult configAvFilterStreamType(AvStreamType type, uint64_t filterId);
|
||||||
AssertionResult configIpFilterCid(uint32_t ipCid, uint64_t filterId);
|
AssertionResult configIpFilterCid(uint32_t ipCid, uint64_t filterId);
|
||||||
AssertionResult configureMonitorEvent(uint64_t filterId, uint32_t monitorEventTypes);
|
AssertionResult configureMonitorEvent(uint64_t filterId, uint32_t monitorEventTypes);
|
||||||
|
AssertionResult testMonitorEvent(uint64_t filterId, uint32_t monitorEventTypes);
|
||||||
AssertionResult getFilterMQDescriptor(uint64_t filterId, bool getMqDesc);
|
AssertionResult getFilterMQDescriptor(uint64_t filterId, bool getMqDesc);
|
||||||
AssertionResult startFilter(uint64_t filterId);
|
AssertionResult startFilter(uint64_t filterId);
|
||||||
AssertionResult stopFilter(uint64_t filterId);
|
AssertionResult stopFilter(uint64_t filterId);
|
||||||
|
|
|
@ -48,6 +48,11 @@ void TunerFilterHidlTest::configSingleFilterInDemuxTest(FilterConfig1_1 filterCo
|
||||||
}
|
}
|
||||||
ASSERT_TRUE(mFilterTests.getFilterMQDescriptor(filterId, filterConf.config1_0.getMqDesc));
|
ASSERT_TRUE(mFilterTests.getFilterMQDescriptor(filterId, filterConf.config1_0.getMqDesc));
|
||||||
ASSERT_TRUE(mFilterTests.startFilter(filterId));
|
ASSERT_TRUE(mFilterTests.startFilter(filterId));
|
||||||
|
ASSERT_TRUE(mFrontendTests.tuneFrontend(frontendConf, true /*testWithDemux*/));
|
||||||
|
if (filterConf.monitorEventTypes > 0) {
|
||||||
|
ASSERT_TRUE(mFilterTests.testMonitorEvent(filterId, filterConf.monitorEventTypes));
|
||||||
|
}
|
||||||
|
ASSERT_TRUE(mFrontendTests.stopTuneFrontend(true /*testWithDemux*/));
|
||||||
ASSERT_TRUE(mFilterTests.stopFilter(filterId));
|
ASSERT_TRUE(mFilterTests.stopFilter(filterId));
|
||||||
ASSERT_TRUE(mFilterTests.closeFilter(filterId));
|
ASSERT_TRUE(mFilterTests.closeFilter(filterId));
|
||||||
ASSERT_TRUE(mDemuxTests.closeDemux());
|
ASSERT_TRUE(mDemuxTests.closeDemux());
|
||||||
|
|
Loading…
Reference in a new issue