Skip to content

Commit 6fd85f3

Browse files
Fix test
1 parent 9fc0fcb commit 6fd85f3

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

rest-api-spec/src/yamlRestTest/resources/rest-api-spec/test/search.highlight/30_max_analyzed_offset.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,10 @@ setup:
130130
rest_total_hits_as_int: true
131131
index: test1
132132
body: {"query" : {"match" : {"field2" : "fox"}}, "highlight" : {"type" : "plain", "fields" : {"field2" : {}}, "max_analyzed_offset": 0}}
133-
- match: { hits.hits.0.highlight: null }
133+
- match: { status: 400 }
134+
- match: { error.root_cause.0.type: "x_content_parse_exception" }
135+
- match: { error.caused_by.type: "illegal_argument_exception" }
136+
- match: { error.caused_by.reason: "[max_analyzed_offset] must be a positive integer, or -1" }
134137

135138
---
136139
"Plain highlighter on a field WITH OFFSETS exceeding index.highlight.max_analyzed_offset with max_analyzed_offset=1 should SUCCEED":

0 commit comments

Comments
 (0)