refactor unit test to support future tests