@Test public void testResponseWriterDoesntSetBase64EncodedFlagIfBinaryHeaderSetToFalse() throws IOException { Map<String, List<String>> headers = new HashMap<>(); headers.put(GatewayBinaryResponseFilter.HEADER_BINARY_RESPONSE, Collections.singletonList("false")); SimpleResponseWriter<GatewayResponse> responseWriter = gatewayHandler.createResponseWriter(null); responseWriter.writeResponse(Status.OK, headers, new ByteArrayOutputStream()); assertFalse(responseWriter.getResponse().isIsBase64Encoded()); }
@Override protected SimpleResponseWriter<GatewayResponse> createResponseWriter( GatewayRequestAndLambdaContext requestAndContext) { return new ResponseWriter(); }
GatewayRequestHandler extends SimpleRequestHandler<GatewayRequestAndLambdaContext, GatewayResponse> { @Override protected SimpleResponseWriter<GatewayResponse> createResponseWriter( GatewayRequestAndLambdaContext requestAndContext) { return new ResponseWriter(); } }
GatewayRequestHandler extends SimpleRequestHandler<GatewayRequestAndLambdaContext, GatewayResponse> { @Override protected SimpleResponseWriter<GatewayResponse> createResponseWriter( GatewayRequestAndLambdaContext requestAndContext) { return new ResponseWriter(); } protected  GatewayRequestHandler(); }
GatewayRequestHandler extends SimpleRequestHandler<GatewayRequestAndLambdaContext, GatewayResponse> { @Override protected SimpleResponseWriter<GatewayResponse> createResponseWriter( GatewayRequestAndLambdaContext requestAndContext) { return new ResponseWriter(); } protected  GatewayRequestHandler();  }
GatewayRequestHandler extends SimpleRequestHandler<GatewayRequestAndLambdaContext, GatewayResponse> { @Override protected SimpleResponseWriter<GatewayResponse> createResponseWriter( GatewayRequestAndLambdaContext requestAndContext) { return new ResponseWriter(); } protected  GatewayRequestHandler();   }