private RestRequest getRequestFromUrl(RestMethod restMethod, String url) throws Exception {
    JSONObject request = new JSONObject();
    request.put(MockRestRequest.REST_METHOD_KEY, restMethod.name());
    request.put(MockRestRequest.URI_KEY, url);
    return new MockRestRequest(request, null);
  }
Gets a {@link RestRequest} from {@code url}.
@param restMethod the {@link RestMethod} of the request.
@param url the url of the request.
@return a {@link RestRequest} from {@code url}.
@throws Exception
ambry-frontend/src/test/java/com/github/ambry/frontend/AmbryUrlSigningServiceTest.java