Refactoring files and adding Appointment Test