Document API IEC60730 Library
|
Header file list of test cases for the verification operate functions in invariable memory module. More...
Functions | |
uint32_t * | unit_test_iec60730_imc_mock_init_run_crc (void) |
sl_iec60730_test_result_t | unit_test_mock_check_integrity (void) |
bool | unit_test_iec60730_imc_mock_enable_gpcrc (void) |
bool | unit_test_iec60730_imc_mock_sw_enable_cal_crc (void) |
void | test_sl_iec60730_imc_init_param_null (void) |
void | test_sl_iec60730_imc_post_pass_check (void) |
void | test_sl_iec60730_imc_post_fail_check (void) |
void | test_sl_iec60730_imc_bist_pass_all_check (void) |
void | test_sl_iec60730_imc_bist_fail_check_integrity (void) |
void | test_sl_iec60730_imc_bist_iec60730_run_crc_greater_than_rom_end_address (void) |
void | test_sl_iec60730_imc_bist_fail_compare_crc (void) |
void | test_sl_iec60730_update_crc_with_data_buffer_params_null (void) |
void | test_sl_iec60730_update_crc_with_data_buffer_calculation_crc (void) |
Header file list of test cases for the verification operate functions in invariable memory module.
IEC60730 Invariable Memory Unit Tests
These test cases run unit tests to check the operation of the functions in invariable memory module.
Hardware setup:
void test_sl_iec60730_imc_bist_fail_check_integrity | ( | void | ) |
Public Check sl_iec60730_imc_bist() operate
If the check integrity of the pointer fails, the function sl_iec60730_imc_bist() returns SL_IEC60730_TEST_FAILED.
void test_sl_iec60730_imc_bist_fail_compare_crc | ( | void | ) |
Public Check sl_iec60730_imc_bist() operate
In the case of SL_IEC60730_CRC_DEBUG_ENABLE == 1, if the value crc calculated value is not equal value calculated from sl_iec60730_imc_post(), or in the case of SL_IEC60730_CRC_DEBUG_ENABLE == 0, the initial crc calculated value is not equal to the value stored in check_sum. The function sl_iec60730_imc_bist() returns SL_IEC60730_TEST_FAILED.
void test_sl_iec60730_imc_bist_iec60730_run_crc_greater_than_rom_end_address | ( | void | ) |
Public Check sl_iec60730_imc_bist() operate
If iec60730_run_crc init greater than rom end address before iec60730_cur_crc is calculated. Then the function sl_iec60730_imc_bist() returns SL_IEC60730_TEST_FAILED.
void test_sl_iec60730_imc_bist_pass_all_check | ( | void | ) |
Public Check sl_iec60730_imc_bist() operate
In the case of SL_IEC60730_CRC_DEBUG_ENABLE == 1, if the value crc calculated value is equal value calculated from sl_iec60730_imc_post(), or in the case of SL_IEC60730_CRC_DEBUG_ENABLE == 0, the initial crc calculated value is equal to the value stored in check_sum. The function returns# SL_IEC60730_TEST_PASSED.
Public Check sl_iec60730_imc_bist() operate
In the case of SL_IEC60730_CRC_DEBUG_ENABLE == 1, if the value crc calculated value is equal value calculated from sl_iec60730_imc_post(), or in the case of SL_IEC60730_CRC_DEBUG_ENABLE == 0, the initial crc calculated value is equal to the value stored in check_sum. The function sl_iec60730_imc_bist() returns SL_IEC60730_TEST_PASSED.
void test_sl_iec60730_imc_init_param_null | ( | void | ) |
Public Check sl_iec60730_imc_init() operate
If the passed parameter value is NULL, the sl_iec60730_imc_init() function will fail. When calling the function sl_iec60730_imc_post(), the value will be returned SL_IEC60730_TEST_FAILED.
void test_sl_iec60730_imc_post_fail_check | ( | void | ) |
Public Check sl_iec60730_imc_post() operate
In the case of SL_IEC60730_CRC_DEBUG_ENABLE == 1, if the initial crc calculated value is 0, or in the case of SL_IEC60730_CRC_DEBUG_ENABLE == 0, the initial crc calculated value is not equal to the value stored in check_sum. The function returns SL_IEC60730_TEST_FAILED.
void test_sl_iec60730_imc_post_pass_check | ( | void | ) |
Public Check sl_iec60730_imc_post() operate
If the passed parameter value is valid, the sl_iec60730_imc_init() function will success. When calling the function sl_iec60730_imc_post(), the value will be returned SL_IEC60730_TEST_PASSED.
void test_sl_iec60730_update_crc_with_data_buffer_calculation_crc | ( | void | ) |
Public Check sl_iec60730_update_crc_with_data_buffer() operate
Calculate the CRC value of the input string, check whether the returned CRC value is correct or not.
void test_sl_iec60730_update_crc_with_data_buffer_params_null | ( | void | ) |
Public Check sl_iec60730_update_crc_with_data_buffer() operate
If the passed parameter value is NULL, the sl_iec60730_update_crc_with_data_buffer() function will fail. returns SL_IEC60730_TEST_FAILED.
bool unit_test_iec60730_imc_mock_enable_gpcrc | ( | void | ) |
Public Function mock enable gpcrc hardware operate.
uint32_t* unit_test_iec60730_imc_mock_init_run_crc | ( | void | ) |
Public Function mock returns the starting address value of the ram test area
bool unit_test_iec60730_imc_mock_sw_enable_cal_crc | ( | void | ) |
Public Function mock enable calculate crc by software.
sl_iec60730_test_result_t unit_test_mock_check_integrity | ( | void | ) |
Public Function simulates the result of variable value integrity check.