refine test framework