restructure the unit test