def METHOD_NAME(self, **kwargs):
    formrecognizer_test_api_key = kwargs.get("formrecognizer_test_api_key", None)
    with open(self.identity_document_license_jpg, "rb") as fd:
        my_file = fd.read()
    with pytest.raises(ServiceRequestError):
        client = FormRecognizerClient("http://notreal.azure.com", AzureKeyCredential(formrecognizer_test_api_key))
        poller = client.begin_recognize_identity_documents(my_file)