@Test
  public void notSignedRequestFailuresTest() throws Exception {
    // positive test done in signAndVerifyTest()
    AmbryUrlSigningService signer = getUrlSignerWithDefaults(new MockTime());
    RestRequest request = getRequestFromUrl(RestMethod.GET, "/");
    assertFalse("Request should not be declared signed", signer.isRequestSigned(request));
    ensureVerificationFailure(signer, request, RestServiceErrorCode.InternalServerError);
    request.setArg(RestUtils.Headers.URL_TYPE, RestMethod.POST.name());
    assertFalse("Request should not be declared signed", signer.isRequestSigned(request));
    ensureVerificationFailure(signer, request, RestServiceErrorCode.InternalServerError);
  }
Tests for some failure scenarios in verification.
@throws Exception
ambry-frontend/src/test/java/com/github/ambry/frontend/AmbryUrlSigningServiceTest.java