'Test generate certificates exceptions api endpoint returns success
when called with existing certificate exception'

def test_generate_certificate_exceptions_all_students(self):

    url = reverse('generate_certificate_exceptions', kwargs={'course_id': unicode(self.course.id), 'generate_for': 'all'})
    response = self.client.post(url, content_type='application/json')
    self.assertEqual(response.status_code, 200)
    res_json = json.loads(response.content)
    self.assertTrue(res_json['success'])
    self.assertEqual(res_json['message'], u'Certificate    generation    started    for    white    listed    students.')
