|
64 | 64 | #define MSG_TRNG_TEST_STEP2 "check_step2"
|
65 | 65 | #define MSG_TRNG_TEST_SUITE_ENDED "Test_suite_ended"
|
66 | 66 |
|
| 67 | +#define RESULT_SUCCESS 0 |
| 68 | + |
67 | 69 | #define NVKEY 1 //NVstore key for storing and loading data
|
68 | 70 |
|
69 | 71 | /*there are some issues with nvstore and greentea reset, so for now nvstore is disabled,
|
@@ -114,7 +116,7 @@ static void compress_and_compare(char *key, char *value)
|
114 | 116 | #if NVSTORE_RESET
|
115 | 117 | uint16_t actual = 0;
|
116 | 118 | result = nvstore.get(NVKEY, sizeof(buffer), buffer, actual);
|
117 |
| - TEST_ASSERT_EQUAL(NVSTORE_SUCCESS, result); |
| 119 | + TEST_ASSERT_EQUAL(RESULT_SUCCESS, result); |
118 | 120 | #else
|
119 | 121 | /*Using base64 to decode data sent from host*/
|
120 | 122 | uint32_t lengthWritten = 0;
|
@@ -173,11 +175,11 @@ static void compress_and_compare(char *key, char *value)
|
173 | 175 | int result = 0;
|
174 | 176 | #if NVSTORE_RESET
|
175 | 177 | result = nvstore.set(NVKEY, sizeof(buffer), buffer);
|
176 |
| - TEST_ASSERT_EQUAL(NVSTORE_SUCCESS, result); |
| 178 | + TEST_ASSERT_EQUAL(RESULT_SUCCESS, result); |
177 | 179 | #else
|
178 | 180 | /*Using base64 to encode data sending from host*/
|
179 | 181 | result = trng_EncodeBase64(buffer, BUFFER_LEN, (char *)out_comp_buf, sizeof(out_comp_buf));
|
180 |
| - TEST_ASSERT_EQUAL(NVSTORE_SUCCESS, result); |
| 182 | + TEST_ASSERT_EQUAL(RESULT_SUCCESS, result); |
181 | 183 | greentea_send_kv(MSG_TRNG_BUFFER, (const char *)out_comp_buf);
|
182 | 184 | #endif
|
183 | 185 | system_reset();
|
|
0 commit comments