Added functional tests - chapter 2