Redesign to reuse test cases