Skip to content

Commit 1511506

Browse files
committed
Add module back, and optionally include it for snapshot builds
1 parent 184e74d commit 1511506

File tree

2 files changed

+14
-4
lines changed

2 files changed

+14
-4
lines changed

x-pack/plugin/vector-tile/build.gradle

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ dependencies {
3838
clusterModules project(':modules:analysis-common')
3939
clusterModules project(':modules:legacy-geo')
4040
clusterModules project(':modules:lang-painless')
41+
clusterModules project(':test:external-modules:test-error-query')
4142
}
4243

4344
tasks.named("thirdPartyAudit").configure {

x-pack/plugin/vector-tile/src/javaRestTest/java/org/elasticsearch/xpack/vectortile/VectorTileRestIT.java

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,10 +50,19 @@
5050
public class VectorTileRestIT extends ESRestTestCase {
5151

5252
@ClassRule
53-
public static ElasticsearchCluster cluster = ElasticsearchCluster.local()
54-
.module("vector-tile")
55-
.setting("xpack.license.self_generated.type", "trial")
56-
.build();
53+
public static ElasticsearchCluster cluster = buildCluster();
54+
55+
private static ElasticsearchCluster buildCluster() {
56+
var builder = ElasticsearchCluster.local().module("vector-tile").setting("xpack.license.self_generated.type", "trial");
57+
58+
if (Build.current().isSnapshot()) {
59+
// This module is not available in non-snapshot builds
60+
// The tests below that use it are disabled in non-snapshot builds
61+
builder.module("test-error-query");
62+
}
63+
64+
return builder.build();
65+
}
5766

5867
private static final String INDEX_POINTS = "index-points";
5968
private static final String INDEX_POLYGON = "index-polygon";

0 commit comments

Comments
 (0)