<commit_before>from django.contrib.admin.sites import AdminSite
from django.contrib.auth.models import User
from django.test import TestCase
try:
    from django.urls import reverse
except ImportError:
    # Supports backward compatibility with 1.9
    from django.core.urlresolvers import reverse

from versions.admin import VersionedAdmin
from ..models import City


class VersionedAdminTest(TestCase):<commit_msg>fixes test errors when using with custom user model<commit_after>from django.contrib.admin.sites import AdminSite
from django.contrib.auth import get_user_model
from django.test import TestCase
try:
    from django.urls import reverse
except ImportError:
    # Supports backward compatibility with 1.9
    from django.core.urlresolvers import reverse

from versions.admin import VersionedAdmin
from ..models import City

User = get_user_model()


class VersionedAdminTest(TestCase):
{'fraction_non_alphanumeric': 0.053452115812917596, 'fraction_numerical': 0.004454342984409799, 'mean_word_length': 5.157534246575342, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7640677', 'n_tokens_mistral': 236, 'n_tokens_neox': 231, 'n_words': 85}