1818import static org .assertj .core .api .Assertions .*;
1919import static org .mockito .Mockito .*;
2020
21- import java .util .List ;
21+ import java .util .Arrays ;
2222
2323import org .assertj .core .api .InstanceOfAssertFactories ;
2424import org .junit .jupiter .api .Test ;
2727
2828/**
2929 * @author Christoph Strobl
30+ * @author Julia Lee
3031 */
3132public class AggregationOperationRendererUnitTests {
3233
@@ -37,7 +38,7 @@ void nonFieldsExposingAggregationOperationContinuesWithSameContextForNextStage()
3738 AggregationOperation stage1 = mock (AggregationOperation .class );
3839 AggregationOperation stage2 = mock (AggregationOperation .class );
3940
40- AggregationOperationRenderer .toDocument (List . of (stage1 , stage2 ), rootContext );
41+ AggregationOperationRenderer .toDocument (Arrays . asList (stage1 , stage2 ), rootContext );
4142
4243 verify (stage1 ).toPipelineStages (eq (rootContext ));
4344 verify (stage2 ).toPipelineStages (eq (rootContext ));
@@ -54,7 +55,7 @@ void fieldsExposingAggregationOperationNotExposingFieldsForcesUseOfDefaultContex
5455 when (stage1 .getFields ()).thenReturn (stage1fields );
5556 when (stage1fields .exposesNoFields ()).thenReturn (true );
5657
57- AggregationOperationRenderer .toDocument (List . of (stage1 , stage2 ), rootContext );
58+ AggregationOperationRenderer .toDocument (Arrays . asList (stage1 , stage2 ), rootContext );
5859
5960 verify (stage1 ).toPipelineStages (eq (rootContext ));
6061 verify (stage2 ).toPipelineStages (eq (AggregationOperationRenderer .DEFAULT_CONTEXT ));
@@ -73,7 +74,7 @@ void fieldsExposingAggregationOperationForcesNewContextForNextStage() {
7374
7475 ArgumentCaptor <AggregationOperationContext > captor = ArgumentCaptor .forClass (AggregationOperationContext .class );
7576
76- AggregationOperationRenderer .toDocument (List . of (stage1 , stage2 ), rootContext );
77+ AggregationOperationRenderer .toDocument (Arrays . asList (stage1 , stage2 ), rootContext );
7778
7879 verify (stage1 ).toPipelineStages (eq (rootContext ));
7980 verify (stage2 ).toPipelineStages (captor .capture ());
@@ -98,7 +99,7 @@ void inheritingFieldsExposingAggregationOperationForcesNewContextForNextStageKee
9899
99100 ArgumentCaptor <AggregationOperationContext > captor = ArgumentCaptor .forClass (AggregationOperationContext .class );
100101
101- AggregationOperationRenderer .toDocument (List . of (stage1 , stage2 , stage3 ), rootContext );
102+ AggregationOperationRenderer .toDocument (Arrays . asList (stage1 , stage2 , stage3 ), rootContext );
102103
103104 verify (stage1 ).toPipelineStages (captor .capture ());
104105 verify (stage2 ).toPipelineStages (captor .capture ());
0 commit comments