Add function to return the length of the HID Report

This commit is contained in:
mbanth
2021-06-03 15:53:50 +01:00
parent dab84e56df
commit fd45908ff6
9 changed files with 118 additions and 1 deletions

View File

@@ -36,6 +36,9 @@ void test_unprepared_hidGetReportDescriptor( void )
{
unsigned char* reportDescPtr = hidGetReportDescriptor();
TEST_ASSERT_NULL( reportDescPtr );
unsigned reportLength = hidGetReportLength();
TEST_ASSERT_EQUAL_UINT( 0, reportLength );
}
void test_prepared_hidGetReportDescriptor( void )
@@ -43,6 +46,9 @@ void test_prepared_hidGetReportDescriptor( void )
hidPrepareReportDescriptor();
unsigned char* reportDescPtr = hidGetReportDescriptor();
TEST_ASSERT_NOT_NULL( reportDescPtr );
unsigned reportLength = hidGetReportLength();
TEST_ASSERT_EQUAL_UINT( HID_REPORT_LENGTH, reportLength );
}
void test_reset_unprepared_hidGetReportDescriptor( void )