Implemented functional testing