public int count(SearchRequest searchRequest)
 {
     Dictionary<string, int> responseMap = (Dictionary<string, int>) callAndConvert("/search/count",
                                                                              new Dictionary<string, int>().
                                                                                GetType(),
                                                                              searchRequest.getQueryParams());
       return responseMap["count"];
 }
        public void countTest()
        {
            SearchRequest searchRequest = new SearchRequest();

              searchRequest.text = "Nintendo";
              searchRequest.source = "E_BAY";
              searchRequest.location = "LAX";

              int count = searchClient.count(searchRequest);
              Assert.IsTrue(count != 0);
        }
        public void searchTest()
        {
            SearchRequest searchRequest = new SearchRequest();

              searchRequest.text = "Nintendo";
              searchRequest.source = "E_BAY";
              searchRequest.location = "LAX";

              SearchResponse searchResponse = searchClient.search(searchRequest);
              Assert.IsTrue(searchResponse.success);
              Assert.IsTrue(searchResponse.numResults > -2);
        }
        public void countTest()
        {
            SearchRequest searchRequest = new SearchRequest();

              searchRequest.text = "Nintendo";
              searchRequest.source = "E_BAY";
              searchRequest.location = "LAX";

              int count = searchClient.count(searchRequest);
              // query is currently returning 0 so unsure what if any to check
              Assert.IsNotNull(count);
        }
        public void rangeTest()
        {
            SearchRequest searchRequest = new SearchRequest();
              searchRequest.text = "Nintendo";

              RangeRequest rangeRequest = new RangeRequest();
              rangeRequest.searchRequest = searchRequest;
              rangeRequest.addField("price");

              RangeResponse response = searchClient.range(rangeRequest);
              //Assert.IsTrue( response.ranges.get("price").getMin() == 0);
              //assert response.getRanges().get("price").getMax() > 0;
        }
        public void summaryTest()
        {
            SearchRequest searchRequest = new SearchRequest();
              searchRequest.text = "Nintendo";

              SummaryRequest summaryRequest = new SummaryRequest();
              summaryRequest.searchRequest = searchRequest;
              summaryRequest.dimension = "source";

              SummaryResponse summaryResponse = searchClient.summary(summaryRequest);
              Assert.IsTrue(summaryResponse.execTimeMs > 0);
              Assert.IsTrue(summaryResponse.totals.ContainsKey("E_BAY"));
        }
 public SearchResponse search(SearchRequest searchRequest)
 {
     return (SearchResponse) callAndConvert("/search",
                                      new SearchResponse().GetType(),
                                      searchRequest.getQueryParams());
 }
 public SearchResponse search(SearchRequest searchRequest)
 {
     throw new NotImplementedException("Implement me");
 }
 public int count(SearchRequest searchRequest)
 {
     throw new NotImplementedException("Implement me");
 }