mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2024-12-24 16:55:31 +00:00
Move the PSA_ASSERT macro to the common helpers file
It's potentially useful in all PSA test suites, of which there are now several.
This commit is contained in:
parent
f055ad7512
commit
0174be2c17
|
@ -90,6 +90,14 @@ typedef struct data_tag
|
|||
} \
|
||||
} while( 0 )
|
||||
|
||||
/** Evaluate an expression and fail the test case if it returns an error.
|
||||
*
|
||||
* \param expr The expression to evaluate. This is typically a call
|
||||
* to a \c psa_xxx function that returns a value of type
|
||||
* #psa_status_t.
|
||||
*/
|
||||
#define PSA_ASSERT( expr ) TEST_ASSERT( ( expr ) == PSA_SUCCESS )
|
||||
|
||||
/** Allocate memory dynamically and fail the test case if this fails.
|
||||
*
|
||||
* You must set \p pointer to \c NULL before calling this macro and
|
||||
|
|
|
@ -8,8 +8,6 @@
|
|||
|
||||
#include "psa_crypto_storage.h"
|
||||
|
||||
#define PSA_ASSERT( expr ) TEST_ASSERT( ( expr ) == PSA_SUCCESS )
|
||||
|
||||
typedef enum
|
||||
{
|
||||
CLOSE_BY_CLOSE,
|
||||
|
|
Loading…
Reference in a new issue