In the test cases test_hdmicec_hal_l1_hdmiCecTxAsync_sinkDevice_negative and test_hdmicec_hal_l1_hdmiCecTxAsync_sinkDevice_positive, callback data with NULL pointer will be set
/* Positive result */
result = HdmiCecSetTxCallback(handle, DriverTransmitCallback, 0);
if (HDMI_CEC_IO_SUCCESS != result) { HDMICEC_ASSERT_AUTO_TERM(); UT_FAIL ("HdmiCecSetTxCallback failed"); }
However in the call back function DriverTransmitCallback, there is a checker UT_ASSERT_PTR_NULL.
void DriverTransmitCallback(int handle, void *callbackData, int result)
{
UT_ASSERT_TRUE(handle!=0);
UT_ASSERT_PTR_NULL((bool)(!callbackData));
//UT_ASSERT_TRUE( (unsigned long long)callbackData== (unsigned long long)0xDEADBEEF);
UT_LOG ("\ncallbackData returned: %x result: %d\n",callbackData, result);
if (HDMI_CEC_IO_SUCCESS != result) { HDMICEC_ASSERT_AUTO_TERM(); UT_FAIL ("Check failed"); }
}
Therefore the test case will always fail when HdmiCecTxAsync is called.
result = HdmiCecTxAsync(handle, buf, len);
if (HDMI_CEC_IO_SUCCESS != result) { HDMICEC_ASSERT_AUTO_TERM(); UT_FAIL ("HdmiCecTxAsync failed"); }
In the test cases test_hdmicec_hal_l1_hdmiCecTxAsync_sinkDevice_negative and test_hdmicec_hal_l1_hdmiCecTxAsync_sinkDevice_positive, callback data with NULL pointer will be set
However in the call back function DriverTransmitCallback, there is a checker UT_ASSERT_PTR_NULL.
Therefore the test case will always fail when HdmiCecTxAsync is called.