mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-08-07 06:42:56 +03:00
Clarify that the "FATAL" message is expected
The test case "Memory buffer small buffer" emits a message "FATAL: verification of first header failed". In this test case, it's actually expected, but it looks weird to see this message from a passing test. Add a comment that states this explicitly, and modify the test description to indicate that the failure is expected, and change the test function name to be more accurate. Fix #309
This commit is contained in:
@@ -232,11 +232,14 @@ exit:
|
||||
/* END_CASE */
|
||||
|
||||
/* BEGIN_CASE depends_on:MBEDTLS_MEMORY_DEBUG */
|
||||
void memory_buffer_small_buffer( )
|
||||
void memory_buffer_heap_too_small( )
|
||||
{
|
||||
unsigned char buf[1];
|
||||
|
||||
mbedtls_memory_buffer_alloc_init( buf, sizeof( buf ) );
|
||||
/* With MBEDTLS_MEMORY_DEBUG enabled, this prints a message
|
||||
* "FATAL: verification of first header failed".
|
||||
*/
|
||||
TEST_ASSERT( mbedtls_memory_buffer_alloc_verify() != 0 );
|
||||
}
|
||||
/* END_CASE */
|
||||
|
Reference in New Issue
Block a user