Fixes for custom user models

As stated on bitbucket, ```get_user_model``` should not be called on module level. It can lead to model not being installed yet. Also, it is necessary to use user model string for defining reference to user model not, hardcoded model instance (which would lead to same errors as previous thing).

There is still some work left on tests, which really doesn't consider anything else then standard Django model. It will fail totally if User model is different (e.g. doesn't have username, but just email).