'Certificate activation should fail when user has not read access to course then permission denied exception
should raised.'

@ddt.data(C4X_SIGNATORY_PATH, SIGNATORY_PATH)
def test_certificate_activation_failure(self, signatory_path):

    test_url = reverse_course_url('certificates.certificate_activation_handler', self.course.id)
    (test_user_client, test_user) = self.create_non_staff_authed_user_client()
    CourseEnrollment.enroll(test_user, self.course.id)
    self._add_course_certificates(count=1, signatory_count=2, asset_path_format=signatory_path)
    response = test_user_client.post(test_url, data=json.dumps({'is_active': True}), content_type='application/json', HTTP_ACCEPT='application/json', HTTP_X_REQUESTED_WITH='XMLHttpRequest')
    self.assertEquals(response.status_code, 403)
    course = self.store.get_course(self.course.id)
    certificates = course.certificates['certificates']
    self.assertEqual(certificates[0].get('is_active'), False)
