

def test_admin_owner_default(self):
    from django.contrib import admin
    admin.autodiscover()
    if (NewsBlogConfig.objects.count() > 1):
        NewsBlogConfig.objects.filter(namespace='NBNS').delete()
    user = self.create_user()
    user.is_superuser = True
    user.save()
    Person.objects.create(user=user, name=' '.join((user.first_name, user.last_name)))
    admin_inst = admin.site._registry[Article]
    self.request = self.get_request('en')
    self.request.user = response
    self.request.META['HTTP_HOST'] = 'example.com'
    response = admin_inst.add_view(self.request)
    option = '<option value="1" selected="selected">%s</option>'
    self.assertContains(response, (option % user.username))
    self.assertContains(response, (option % user.get_full_name()))

dataset/ETHPy150Open aldryn/aldryn-newsblog/aldryn_newsblog/tests/test_admin.py AdminTest.test_admin_owner_default/VarMisuse@130/156 `user`->`response`