Remove direct writing to `test_info` from `*.function`
Add a new function `mbedtls_test_info_reset()` to remove direct writes to
`mbedtls_test_info`. This change still allows values to be read directly
however all writes are now done inside of `helpers.c`.
Also slightly reordered code to make it easier to read.
Signed-off-by: Chris Jones <christopher.jones@arm.com>
diff --git a/tests/suites/target_test.function b/tests/suites/target_test.function
index 7866dcf..8afe70e 100644
--- a/tests/suites/target_test.function
+++ b/tests/suites/target_test.function
@@ -384,8 +384,7 @@
while ( 1 )
{
ret = 0;
- mbedtls_test_info.result = MBEDTLS_TEST_RESULT_SUCCESS;
- mbedtls_test_info.step = (unsigned long)( -1 );
+ mbedtls_test_info_reset();
data_len = 0;
data = receive_data( &data_len );