Adding chap06 test code