fix unit test app to print tests in the same order they are given in files

This commit is contained in:
antti 2017-01-23 12:54:35 +08:00
parent 47d3759474
commit 1e2c5cc151

View file

@ -39,16 +39,17 @@ void unity_flush()
void unity_testcase_register(struct test_desc_t* desc)
{
if (!s_unity_tests_first)
if (!s_unity_tests_first)
{
s_unity_tests_first = desc;
s_unity_tests_last = desc;
}
else
else
{
s_unity_tests_last->next = desc;
struct test_desc_t* temp = s_unity_tests_first;
s_unity_tests_first = desc;
s_unity_tests_first->next = temp;
}
s_unity_tests_last = desc;
desc->next = NULL;
}
static void unity_run_single_test(const struct test_desc_t* test)