unit test cases for utilities and profiles samples, clean up of profileService