'Test for ticket 2445 changes to admin.'

def test_limit_choices_to_as_callable(self):

    threepwood = Character.objects.create(username='threepwood', last_action=(datetime.datetime.today() + datetime.timedelta(days=1)))
    marley = Character.objects.create(username='marley', last_action=(datetime.datetime.today() - datetime.timedelta(days=1)))
    response = self.client.get(reverse('admin:admin_views_stumpjoke_add'))
    self.assertContains(response, threepwood.username, count=2)
    self.assertNotContains(response, marley.username)
