Files
lab-rv32i-freertos-c-notifi…/tests/notifications_model_host.c
T

27 lines
696 B
C

#include <assert.h>
#include "task01_notifications_model.h"
int main( void )
{
NotificationEvidence events[ 12 ];
size_t index;
for( index = 0U; index < 12U; ++index )
{
events[ index ] = ( NotificationEvidence ) {
( uint32_t ) index + 1U,
( uint32_t ) index + 1U,
0U,
( uint32_t ) index,
( uint32_t ) index,
0xFC100000U | ( ( uint32_t ) index + 1U )
};
}
assert( fc10_order_is_valid( events, 12U ) != 0 );
assert( fc10_digest( events, 12U ) == fc10_digest( events, 12U ) );
events[ 8 ].sequence = 0U;
assert( fc10_order_is_valid( events, 12U ) == 0 );
return 0;
}