Skip to content

Commit

Permalink
fix test failures
Browse files Browse the repository at this point in the history
Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
  • Loading branch information
nknize committed Feb 15, 2022
1 parent 766652d commit 2222b38
Show file tree
Hide file tree
Showing 5 changed files with 2 additions and 195 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,9 @@ public TermVectorsResponse(String index, String id, long version, boolean found,
"term_vectors",
true,
args -> {
// as the response comes from server, we are sure that args[6] will be a list of TermVector
// as the response comes from server, we are sure that args[5] will be a list of TermVector
@SuppressWarnings("unchecked")
List<TermVector> termVectorList = (List<TermVector>) args[6];
List<TermVector> termVectorList = (List<TermVector>) args[5];
if (termVectorList != null) {
Collections.sort(termVectorList, Comparator.comparing(TermVector::getFieldName));
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,6 @@ public void testMultiParser() throws Exception {
request.add(new TermVectorsRequest(), data);

checkParsedParameters(request);
assertWarnings(RestTermVectorsAction.TYPES_DEPRECATION_MESSAGE);
}

void checkParsedParameters(MultiTermVectorsRequest request) {
Expand Down Expand Up @@ -361,7 +360,6 @@ public void testMultiParserFilter() throws Exception {
request.add(new TermVectorsRequest(), data);

checkParsedFilterParameters(request);
assertWarnings(RestTermVectorsAction.TYPES_DEPRECATION_MESSAGE);
}

void checkParsedFilterParameters(MultiTermVectorsRequest multiRequest) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -472,11 +472,6 @@ public void testFromJson() throws IOException {
protected QueryBuilder parseQuery(XContentParser parser) throws IOException {
QueryBuilder query = super.parseQuery(parser);
assertThat(query, instanceOf(MoreLikeThisQueryBuilder.class));

if (!assertedWarnings.contains(MoreLikeThisQueryBuilder.TYPES_DEPRECATION_MESSAGE)) {
assertWarnings(MoreLikeThisQueryBuilder.TYPES_DEPRECATION_MESSAGE);
assertedWarnings.add(MoreLikeThisQueryBuilder.TYPES_DEPRECATION_MESSAGE);
}
return query;
}

Expand Down

This file was deleted.

This file was deleted.

0 comments on commit 2222b38

Please sign in to comment.