added NSError category, refactored response serializer and auth tests