Skip to content

Commit 93b3584

Browse files
authored
Account for using ML snapshot builds in HLRC release tests (#90066)
Since #89951 we use ML snapshot builds in all elasticsearch-ci jobs, even the release-tests ones. The test of the reported ML native code version in the HLRC tests needs to account for this. This change is 7.17 only, as the HLRC is removed in 8.x.
1 parent af1d803 commit 93b3584

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

client/rest-high-level/src/test/java/org/elasticsearch/client/PingAndInfoIT.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@
1919
import java.util.EnumSet;
2020
import java.util.Map;
2121

22+
import static org.hamcrest.Matchers.startsWith;
23+
2224
public class PingAndInfoIT extends ESRestHighLevelClientTestCase {
2325

2426
public void testPing() throws IOException {
@@ -71,7 +73,9 @@ public void testXPackInfo() throws Exception {
7173
FeatureSet ml = info.getFeatureSetsInfo().getFeatureSets().get("ml");
7274
assertTrue(ml.available());
7375
assertTrue(ml.enabled());
74-
assertEquals(mainResponse.getVersion().getNumber(), ml.nativeCodeInfo().get("version").toString());
76+
// startsWith because since https://github.com/elastic/elasticsearch/pull/89951 the
77+
// release-tests CI jobs use ML snapshot builds
78+
assertThat(ml.nativeCodeInfo().get("version").toString(), startsWith(mainResponse.getVersion().getNumber()));
7579
}
7680

7781
public void testXPackInfoEmptyRequest() throws IOException {

0 commit comments

Comments
 (0)