Getting the error
CommandError: One or more models did not validate:
admin.logentry: 'user' has a relation with model su.SuUser, which has either not been installed or is abstract.`
when I run python manage.py test
.
su is my user app, and app is where most of the work is done.
settings.py
INSTALLED_APPS = (
...
"su",
"app",
)
AUTH_USER_MODEL = 'su.SuUser'
su/models.py
class SuUser(AbstractBaseUser, PermissionsMixin):
username = models.CharField(_('User name'), max_length=254, unique=True, db_index=True)
...
class Meta:
app_label = 'su'
app/tests.py
from django_nose import FastFixtureTestCase as TestCase
from nose.tools import assert_equals
from django.contrib.auth import get_user_model
from django.test.utils import override_settings
User = get_user_model()
@override_settings(AUTH_USER_MODEL='su.SuUser')
class TestApp(TestCase):
...
Any idea? syncdb
works fine. Running the app works fine.
EDIT 1
Even if I try to skip the custom user such as
@skipIfCustomUser
class TestApp(TestCase):
...
still getting the same errors.