Added Unit-testing
Changed CoreDataManager.