'Test certificate url is empty if html view is not enabled and certificate is not yet generated'

@patch.dict(settings.FEATURES, {'CERTIFICATES_HTML_VIEW': False})
def test_cert_url_empty_with_invalid_certificate(self):

    url = certs_api.get_certificate_url(self.student.id, self.course.id)
    self.assertEqual(url, '')
