Skip to content

Commit 1632929

Browse files
authored
Fix test EsqlNodeFailureIT - use correct exception class (#119326)
1 parent c0553d4 commit 1632929

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

x-pack/plugin/esql/src/internalClusterTest/java/org/elasticsearch/xpack/esql/action/EsqlNodeFailureIT.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77

88
package org.elasticsearch.xpack.esql.action;
99

10-
import org.elasticsearch.ElasticsearchException;
1110
import org.elasticsearch.action.index.IndexRequestBuilder;
1211
import org.elasticsearch.common.util.CollectionUtils;
1312
import org.elasticsearch.plugins.Plugin;
@@ -58,7 +57,7 @@ public void testFailureLoadingFields() throws IOException {
5857
docs.add(client().prepareIndex("fail").setSource("foo", 0));
5958
indexRandom(true, docs);
6059

61-
ElasticsearchException e = expectThrows(ElasticsearchException.class, () -> run("FROM fail,ok | LIMIT 100").close());
60+
IllegalStateException e = expectThrows(IllegalStateException.class, () -> run("FROM fail,ok | LIMIT 100").close());
6261
assertThat(e.getMessage(), equalTo("Accessing failing field"));
6362
}
6463
}

0 commit comments

Comments
 (0)