Merge branch 'master' into index-lifecycle

This commit is contained in:
Tal Levy 2018-02-12 14:17:24 -08:00
parent 0a3dcebca0
commit 8e282f21c8
2 changed files with 5 additions and 5 deletions

View File

@ -25,6 +25,7 @@ import org.elasticsearch.cluster.service.ClusterService;
import org.elasticsearch.common.bytes.BytesReference;
import org.elasticsearch.common.collect.ImmutableOpenMap;
import org.elasticsearch.common.io.stream.Writeable.Reader;
import org.elasticsearch.common.xcontent.DeprecationHandler;
import org.elasticsearch.common.xcontent.XContentHelper;
import org.elasticsearch.common.xcontent.XContentParser;
import org.elasticsearch.common.xcontent.XContentType;
@ -71,7 +72,8 @@ public class ForceMergeActionTests extends AbstractSerializingTestCase<ForceMerg
public void testMissingMaxNumSegments() throws IOException {
BytesReference emptyObject = JsonXContent.contentBuilder().startObject().endObject().bytes();
XContentParser parser = XContentHelper.createParser(null, emptyObject, XContentType.JSON);
XContentParser parser = XContentHelper.createParser(null, DeprecationHandler.THROW_UNSUPPORTED_OPERATION,
emptyObject, XContentType.JSON);
Exception e = expectThrows(IllegalArgumentException.class, () -> ForceMergeAction.parse(parser));
assertThat(e.getMessage(), equalTo("Required [max_num_segments]"));
}

View File

@ -17,10 +17,8 @@ licenseHeaders.enabled = false
integTest.enabled = false
dependencies {
provided "org.elasticsearch:elasticsearch:${version}"
provided "org.elasticsearch.plugin:x-pack-core:${version}"
testCompile project(path: ':x-pack-elasticsearch:plugin:core', configuration: 'testArtifacts')
compileOnly "org.elasticsearch.plugin:x-pack-core:${version}"
testCompile project(path: xpackModule('core'), configuration: 'testArtifacts')
}
dependencyLicenses {