refactor tests
finish chapter 5