docstr: Test calling root_path on an instance of ASGIProxyRequest.
  
  When the root_path is not passed into the scope, it returns empty string.
  When calling set_root_path, it correctly sets the root_path. When the
  root_path is passed into the scope, it returns the correct value.
docstr_tok: ["Test","calling","root_path","on","an","instance","of","ASGIProxyRequest",".","When","the","root_path","is","not","passed","into","the","scope",",","it","returns","empty","string",".","When","calling","set_root_path",",","it","correctly","sets","the","root_path",".","When","the","root_path","is","passed","into","the","scope",",","it","returns","the","correct","value","."]
code: def test_root_path(self):
      """Test calling root_path on an instance of ASGIProxyRequest.
  
      When the root_path is not passed into the scope, it returns empty string.
      When calling set_root_path, it correctly sets the root_path. When the
      root_path is 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.root_path == ""
  
      root_path = "fake-root_path"
      proxy_request.set_root_path(root_path)
      assert proxy_request.root_path == root_path
  
      proxy_request = self.create_asgi_proxy_request(
          scope={"root_path": root_path}
      )
      assert isinstance(proxy_request, ProxyRequest)
      assert proxy_request.root_path == root_path
  
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 5 for calling the TestASGIProxyRequest obj's underlying member method code with example usage: obj.test_root_path() without return types