added test for profile names fixed bug