def METHOD_NAME(self):
    responses.add(
        responses.POST, "https://splunk.example.com:8088/services/collector", status=500
    )
    self.plugin.set_option("token", "12345678-1234-1234-1234-1234567890AB", self.project)
    self.plugin.set_option("index", "main", self.project)
    self.plugin.set_option("instance", "https://splunk.example.com:8088", self.project)
    event = self.store_event(
        data={"message": "Hello world", "level": "warning"}, project_id=self.project.id
    )
    with self.options({"system.url-prefix": "http://example.com"}):
        with pytest.raises(ApiError):
            self.plugin.post_process(event)