code: def test_score_model_gateway_completions():
      expected_output = {
          "choices": [
              {
                  "text": "man, one giant leap for mankind.",
                  "metadata": {"finish_reason": "stop"},
              }
          ],
          "metadata": {
              "model": "gpt-4-0613",
              "input_tokens": 13,
              "total_tokens": 21,
              "output_tokens": 8,
              "endpoint_type": "llm/v1/completions",
          },
      }
  
      with mock.patch(
          "mlflow.gateway.get_route",
          return_value=Route(
              name="my-route",
              route_type="llm/v1/completions",
              model=RouteModelInfo(provider="openai"),
              route_url="my-route",
          ).to_endpoint(),
      ):
          with mock.patch(
              "mlflow.gateway.query", return_value=expected_output
          ):
              response = score_model_on_payload("gateway:/my-route", {})
              assert response == expected_output["choices"][0]["text"]
  
imports: from unittest import mock
  import pytest
  from mlflow.exceptions import MlflowException
  from mlflow.gateway.config import Route, RouteModelInfo
  from mlflow.metrics.genai.model_utils import _parse_model_uri, score_model_on_payload
label_desc: Use image node_id 14 for calling a global function with example usage: test_score_model_gateway_completions() without return types