RestHttpHelper { public HttpResponse multipartPost(String url, HttpEntity reqEntity) throws Exception { Map<String, String> headers = null; return executeRequest(url, Method.MULTPART, reqEntity, headers); } RestHttpHelper();  RestHttpHelper(int socketTimeoutMs);  RestHttpHelper(Credential credential);  RestHttpHelper(Credential credential, int socketTimeoutMs); HttpResponse get(String url); HttpResponse get(String url,
                            Map<String, String> headers); HttpResponse head(String url); HttpResponse delete(String url); HttpResponse post(String url,
                             String requestContent,
                             Map<String, String> headers); HttpResponse post(String url,
                             String requestContent,
                             String mimeType,
                             Map<String, String> headers); HttpResponse post(String url,
                             InputStream requestContent,
                             String mimeType,
                             long contentLength,
                             Map<String, String> headers); HttpResponse put(String url,
                            String requestContent,
                            Map<String, String> headers); HttpResponse put(String url,
                            String requestContent,
                            String mimeType,
                            Map<String, String> headers); HttpResponse put(String url,
                            InputStream requestContent,
                            String mimeType,
                            long contentLength,
                            Map<String, String> headers); HttpResponse multipartFilePost(String url, File file); HttpResponse multipartFileStreamPost(String url,
                                                String fileName,
                                                InputStream stream); HttpResponse multipartPost(String url, HttpEntity reqEntity);  }
@Test public void testMultipartPost() throws Exception { MultipartEntityBuilder builder = MultipartEntityBuilder.create(); builder.addTextBody("text-part", "text"); builder.addBinaryBody("binary-part", "binary-content".getBytes()); HttpEntity reqEntity = builder.build(); HttpResponse response = helper.multipartPost(getUrl(), reqEntity); verifyResponse(response); }