TC: code cleanup
This commit is contained in:
parent
b66c5ee074
commit
752fe135cd
|
@ -43,6 +43,7 @@ void tc_thread_entry(void* parameter)
|
||||||
/* Make sure we are going to be blocked. */
|
/* Make sure we are going to be blocked. */
|
||||||
rt_sem_control(&_tc_sem, RT_IPC_CMD_RESET, 0);
|
rt_sem_control(&_tc_sem, RT_IPC_CMD_RESET, 0);
|
||||||
rt_sem_take(&_tc_sem, tick * _tc_scale);
|
rt_sem_take(&_tc_sem, tick * _tc_scale);
|
||||||
|
}
|
||||||
|
|
||||||
if (_tc_cleanup != RT_NULL)
|
if (_tc_cleanup != RT_NULL)
|
||||||
{
|
{
|
||||||
|
@ -50,16 +51,6 @@ void tc_thread_entry(void* parameter)
|
||||||
_tc_cleanup();
|
_tc_cleanup();
|
||||||
_tc_cleanup = RT_NULL;
|
_tc_cleanup = RT_NULL;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if (_tc_cleanup != RT_NULL)
|
|
||||||
{
|
|
||||||
/* perform testcase cleanup */
|
|
||||||
_tc_cleanup();
|
|
||||||
_tc_cleanup = RT_NULL;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (_tc_stat & TC_STAT_FAILED)
|
if (_tc_stat & TC_STAT_FAILED)
|
||||||
rt_kprintf("TestCase[%s] failed\n", _tc_current);
|
rt_kprintf("TestCase[%s] failed\n", _tc_current);
|
||||||
|
|
Loading…
Reference in New Issue