docstr: Test calling headers on an instance of ASGIProxyRequest.
  
  When the headers are not passed into the scope, it returns empty list.
  When the headers are passed into the scope, it returns the correct value.
docstr_tok: ["Test","calling","headers","on","an","instance","of","ASGIProxyRequest",".","When","the","headers","are","not","passed","into","the","scope",",","it","returns","empty","list",".","When","the","headers","are","passed","into","the","scope",",","it","returns","the","correct","value","."]
code: def test_headers(self):
      """Test calling headers on an instance of ASGIProxyRequest.
  
      When the headers are not passed into the scope, it returns empty list.
      When the headers are passed into the scope, it returns the correct value.
      """
      proxy_request = self.create_asgi_proxy_request(scope={})
      assert isinstance(proxy_request, ProxyRequest)
      assert proxy_request.headers == []
  
      headers = [(b"fake-header-key", b"fake-header-value")]
      proxy_request = self.create_asgi_proxy_request(
          scope={"headers": headers}
      )
      assert isinstance(proxy_request, ProxyRequest)
      assert proxy_request.headers == headers
  
imports: import pickle
  from unittest.mock import MagicMock
  import pytest
  from ray.serve._private.common import StreamingHTTPRequest, gRPCRequest
  from ray.serve._private.proxy_request_response import ASGIProxyRequest, ProxyRequest, gRPCProxyRequest
  from ray.serve._private.test_utils import FakeGrpcContext
  from ray.serve.generated import serve_pb2
label_desc: Use image node_id 7 for calling the TestASGIProxyRequest obj's underlying member method code with example usage: obj.test_headers() without return types