fixed test code based on changes to problem code