Package com.tistory.devyongsik.crescent.search.service

Source Code of com.tistory.devyongsik.crescent.search.service.SearchServiceImplTest

package com.tistory.devyongsik.crescent.search.service;

import java.io.IOException;

import javax.annotation.PostConstruct;

import junit.framework.Assert;

import org.junit.Test;

import com.tistory.devyongsik.crescent.search.entity.SearchRequest;
import com.tistory.devyongsik.crescent.search.entity.SearchResult;
import com.tistory.devyongsik.utils.CrescentTestCaseUtil;

public class SearchServiceImplTest extends CrescentTestCaseUtil {

  @PostConstruct
  public void init() {
    super.init();
  }
 
  @Test
  public void search() throws IOException {
    SearchRequest searchRequest = new SearchRequest();
    searchRequest.setCollectionName("sample");
    searchRequest.setKeyword("1");
   
    SearchResult searchResult = searchService.search(searchRequest);
   
    Assert.assertTrue(searchResult.getTotalHitsCount() > 0)
  }
}
TOP

Related Classes of com.tistory.devyongsik.crescent.search.service.SearchServiceImplTest

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.