mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-08-05 19:35:48 +03:00
Validate that test_fail causes a test failure
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
This commit is contained in:
@@ -17,6 +17,17 @@
|
|||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
|
|
||||||
|
/****************************************************************/
|
||||||
|
/* Test framework features */
|
||||||
|
/****************************************************************/
|
||||||
|
|
||||||
|
void meta_test_fail(const char *name)
|
||||||
|
{
|
||||||
|
(void) name;
|
||||||
|
mbedtls_test_fail("Forced test failure", __LINE__, __FILE__);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/****************************************************************/
|
/****************************************************************/
|
||||||
/* Command line entry point */
|
/* Command line entry point */
|
||||||
/****************************************************************/
|
/****************************************************************/
|
||||||
@@ -28,6 +39,7 @@ typedef struct {
|
|||||||
} metatest_t;
|
} metatest_t;
|
||||||
|
|
||||||
metatest_t metatests[] = {
|
metatest_t metatests[] = {
|
||||||
|
{ "test_fail", "any", meta_test_fail },
|
||||||
{ NULL, NULL, NULL }
|
{ NULL, NULL, NULL }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user