add test case
add calc average time logic