'Test that user can remove certificate invalidation.'

def test_remove_certificate_invalidation(self):

    self.generated_certificate.invalidate()
    CertificateInvalidationFactory.create(generated_certificate=self.generated_certificate, invalidated_by=self.global_staff)
    response = self.client.post(self.url, data=json.dumps(self.certificate_invalidation_data), content_type='application/json', REQUEST_METHOD='DELETE')
    self.assertEqual(response.status_code, 204)
    with self.assertRaises(ObjectDoesNotExist):
        CertificateInvalidation.objects.get(generated_certificate=self.generated_certificate, invalidated_by=self.global_staff, active=True)
