GetBlimp/django-rest-framework-jwt — pull request #21 by alvinchow86 (2014-06-06 02:33:28+00:00)
Title: Custom User Models + Tests

Added some tests, on top of the pull request https://github.com/GetBlimp/django-rest-framework-jwt/pull/18 from @cborgolte . I have a custom user model with USERNAME_FIELD = 'email' (well not that custom but didn't feel like making one from scratch).

One change I made was remove `username_field` as a class variable from JSONWebTokenSerializer, as it made testing a bit harder (get_user_model() would only be evaluated on module import, and you'd have to do manually reload the module after changing settings.AUTH_USER_MODEL)