Corrected casting issue with an assert within the error_handling test

Discovered via https://github.com/ARMmbed/mbed-os/pull/7105.
If both values are negative values, they are casted in such a way that -1 != -1. This small commit fixes that.
pull/7202/head
Cruz Monrreal 2018-06-12 22:09:51 -05:00 committed by GitHub
parent ed9a1f1327
commit 6fa560930c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -124,7 +124,7 @@ void test_error_context_capture()
mbed_error_status_t status = mbed_get_last_error_info( &error_ctx );
TEST_ASSERT(status == MBED_SUCCESS);
TEST_ASSERT_EQUAL_UINT(error_value, error_ctx.error_value);
TEST_ASSERT_EQUAL_UINT(osThreadGetId(), error_ctx.thread_id);
TEST_ASSERT_EQUAL_UINT((uint32_t)osThreadGetId(), error_ctx.thread_id);
//Capture thread info and compare
osRtxThread_t *current_thread = osRtxInfo.thread.run.curr;