*/
public class SearchRequestBuilderTest extends RequestBuilderTestBase {
@Test
public void buildHttpUriRequest() {
SearchRequest search = new SearchRequest("SearchRequestBuilderTest", new SearchQueryBuilder().build());
setTrackingVariables(search);
search.setFields("fields");
SearchRequestBuilder builder = new SearchRequestBuilder();
HttpUriRequest httpUriRequest = builder.build(search);
Assert.assertEquals(httpUriRequest.getClass(), HttpPost.class);
Assert.assertEquals(httpUriRequest.getURI().getPath(), "/rest/1.0/model/SearchRequestBuilderTest/search");
Map<String, String> params = parseQueryParams(httpUriRequest);
assertContainsTrackingVariables(params);
Assert.assertEquals(params.get("fl"), search.getFields());
}