Test: use less shards in SimpleQueryTests

This commit is contained in:
Boaz Leskes 2014-12-18 09:02:10 +01:00
parent 242e631e95
commit ee7ed387d4
1 changed files with 13 additions and 1 deletions

View File

@ -47,7 +47,9 @@ import org.joda.time.format.ISODateTimeFormat;
import org.junit.Test; import org.junit.Test;
import java.io.IOException; import java.io.IOException;
import java.util.*; import java.util.HashSet;
import java.util.Random;
import java.util.Set;
import java.util.concurrent.ExecutionException; import java.util.concurrent.ExecutionException;
import static org.elasticsearch.cluster.metadata.IndexMetaData.SETTING_NUMBER_OF_REPLICAS; import static org.elasticsearch.cluster.metadata.IndexMetaData.SETTING_NUMBER_OF_REPLICAS;
@ -63,6 +65,16 @@ import static org.hamcrest.Matchers.*;
public class SimpleQueryTests extends ElasticsearchIntegrationTest { public class SimpleQueryTests extends ElasticsearchIntegrationTest {
@Override
protected int maximumNumberOfShards() {
return 7;
}
@Override
protected int maximumNumberOfReplicas() {
return Math.min(2, cluster().numDataNodes() - 1);
}
@Test @Test
public void testOmitNormsOnAll() throws ExecutionException, InterruptedException, IOException { public void testOmitNormsOnAll() throws ExecutionException, InterruptedException, IOException {
assertAcked(prepareCreate("test") assertAcked(prepareCreate("test")