'Tests a valid logout and make sure the logout_time is updated'

def test_valid_logout(self):

    response = self._login(is_valid_username=True, is_valid_password=True)
    self.assertEquals(AccessLog.objects.latest('id').logout_time, None)
    response = self.client.get(reverse('admin:logout'))
    self.assertNotEquals(AccessLog.objects.latest('id').logout_time, None)
    self.assertContains(response, 'Logged    out')
