Skip to content

Commit

Permalink
iter
Browse files Browse the repository at this point in the history
  • Loading branch information
javanna committed Oct 23, 2023
1 parent 7d1f0b9 commit 0d9d123
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1231,7 +1231,8 @@ protected void doXContent(XContentBuilder builder, Params params) throws IOExcep

public static CustomParserQueryBuilder fromXContent(XContentParser parser) throws IOException {
{
assertEquals("list", parser.nextFieldName());
assertEquals(XContentParser.Token.FIELD_NAME, parser.nextToken());
assertEquals("list", parser.currentName());
List<Object> list = parser.list();
assertEquals(3, list.size());
for (int i = 0; i < 3; i++) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -384,14 +384,6 @@ public void testParseMapSupplierUOE() throws Exception {
expectThrows(UnsupportedOperationException.class, () -> dotExpandedParser.map(HashMap::new, XContentParser::text));
}

public void testNextFieldNameUOE() throws Exception {
XContentParser dotExpandedParser = DotExpandingXContentParser.expandDots(
createParser(JsonXContent.jsonXContent, ""),
new ContentPath()
);
expectThrows(UnsupportedOperationException.class, () -> dotExpandedParser.nextFieldName());
}

public void testParseMap() throws Exception {
String jsonInput = """
{"params":{"one":"one",
Expand Down

0 comments on commit 0d9d123

Please sign in to comment.