refactored specs after code review