File tree Expand file tree Collapse file tree 1 file changed +2
-5
lines changed
test/framework/src/main/java/org/elasticsearch/index/mapper Expand file tree Collapse file tree 1 file changed +2
-5
lines changed Original file line number Diff line number Diff line change @@ -1570,7 +1570,7 @@ public void testSyntheticSourceKeepArrays() throws IOException {
15701570 b .endObject ();
15711571 }));
15721572
1573- int elementCount = randomIntBetween (1 , 5 );
1573+ int elementCount = randomIntBetween (2 , 5 );
15741574 CheckedConsumer <XContentBuilder , IOException > buildInput = (XContentBuilder builder ) -> {
15751575 example .buildInputArray (builder , elementCount );
15761576 };
@@ -1581,10 +1581,7 @@ public void testSyntheticSourceKeepArrays() throws IOException {
15811581 builder .endObject ();
15821582 String expected = Strings .toString (builder );
15831583 String actual = syntheticSource (mapperAll , buildInput );
1584- // Check for single-element array, the array source is not stored in this case.
1585- if (expected .replace ("[" , "" ).replace ("]" , "" ).equals (actual ) == false ) {
1586- assertThat (actual , equalTo (expected ));
1587- }
1584+ assertThat (actual , equalTo (expected ));
15881585 }
15891586
15901587 @ Override
You can’t perform that action at this time.
0 commit comments