import org.eclipse.jetty.servlet.DefaultServlet;
import org.eclipse.jetty.servlet.ServletContextHandler;
import org.eclipse.jetty.servlet.ServletHolder;
+import org.fest.assertions.api.Assertions;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
@RunWith( ArchivaSpringJUnit4ClassRunner.class )
@ContextConfiguration( locations = { "classpath*:/META-INF/spring-context.xml", "classpath*:/spring-context.xml" } )
public class DownloadRemoteIndexTaskTest
- extends TestCase
{
private Server server;
public void initialize()
throws Exception
{
- super.setUp();
server = new Server( 0 );
createContext( server, new File( "src/test/" ) );
throws Exception
{
server.stop();
- super.tearDown();
}
@Test
FlatSearchResponse response = nexusIndexer.searchFlat( rq );
log.info( "returned hit count:{}", response.getReturnedHitsCount() );
- assertEquals( 8, response.getReturnedHitsCount() );
+ Assertions.assertThat( response.getReturnedHitsCount() ).isEqualTo( 8 );
}