@@ -49,7 +49,7 @@ void parametrizedWithParameterFieldInjection() {
4949 }
5050
5151 @ ExtendWith (ParameterizedExtension .class )
52- protected static class FibonacciTest {
52+ private static class FibonacciTest {
5353 @ Parameters
5454 public static Collection <Object []> data () {
5555 return Arrays .asList (
@@ -88,7 +88,7 @@ void paremeterizedWithConstructorInjection() {
8888 }
8989
9090 @ ExtendWith (ParameterizedExtension .class )
91- protected static class ParameterizedTestWithConstructor {
91+ private static class ParameterizedTestWithConstructor {
9292 @ Parameters
9393 public static Collection <Object []> data () {
9494 return Arrays .asList (
@@ -116,7 +116,7 @@ void unMatchedConstructorArgumentCount() {
116116 }
117117
118118 @ ExtendWith (ParameterizedExtension .class )
119- protected static class UnMatchedConstructor {
119+ private static class UnMatchedConstructor {
120120 @ Parameters
121121 public static Collection <Object []> data () {
122122 return Arrays .asList (new Object [][] { { 0 , 2 } });
@@ -140,7 +140,7 @@ void unMatchedParameterFieldsCount() {
140140 }
141141
142142 @ ExtendWith (ParameterizedExtension .class )
143- protected static class WrongParameters {
143+ private static class WrongParameters {
144144 @ Parameterized .Parameter
145145 public int a ;
146146 @ Parameterized .Parameter (1 )
@@ -168,7 +168,7 @@ void noInjectionMix() {
168168 }
169169
170170 @ ExtendWith (ParameterizedExtension .class )
171- protected static class DoubleInjection {
171+ private static class DoubleInjection {
172172 @ Parameterized .Parameter
173173 public int a ;
174174
@@ -220,7 +220,7 @@ void emptyParametersList() {
220220 }
221221
222222 @ ExtendWith (ParameterizedExtension .class )
223- protected static class EmptyParameters {
223+ private static class EmptyParameters {
224224
225225 public EmptyParameters () {
226226 }
@@ -243,7 +243,7 @@ void duplicatedParameterFieldIndex() {
243243 }
244244
245245 @ ExtendWith (ParameterizedExtension .class )
246- protected static class DuplicatedIndex {
246+ private static class DuplicatedIndex {
247247 @ Parameterized .Parameter
248248 public int a ;
249249
@@ -268,7 +268,7 @@ void parametersAreOnlyCalledOnce() {
268268 }
269269
270270 @ ExtendWith (ParameterizedExtension .class )
271- protected static class ParametersCalledOnce {
271+ private static class ParametersCalledOnce {
272272 private static int invocationCount = 0 ;
273273
274274 public ParametersCalledOnce (int a ) {
@@ -294,7 +294,7 @@ void multipleTestTemplatesShouldBeRun() {
294294 }
295295
296296 @ ExtendWith (ParameterizedExtension .class )
297- static class MultipleTestTemplates {
297+ private static class MultipleTestTemplates {
298298 private static int invocationCount = 0 ;
299299
300300 public MultipleTestTemplates (int a ) {
@@ -319,6 +319,30 @@ void secondTemplate() {
319319 }
320320 }
321321
322+ @ Test
323+ void singleParameterIterable () {
324+ ExecutionEventRecorder eventRecorder = executeTestsForClass (IterableTest .class );
325+ assertThat (eventRecorder .getTestSuccessfulCount ()).isEqualTo (2 );
326+ }
327+
328+ @ ExtendWith (ParameterizedExtension .class )
329+ private static class IterableTest {
330+
331+ public IterableTest (Object o ) {
332+
333+ }
334+
335+ @ Parameters
336+ public static Object [] data () {
337+ return new Object [] { new Object (), new Object () };
338+ }
339+
340+ @ TestTemplate
341+ void dummy () {
342+
343+ }
344+ }
345+
322346 private ExecutionEventRecorder executeTestsForClass (Class <?> testClass ) {
323347 LauncherDiscoveryRequest request = request ().selectors (selectClass (testClass )).build ();
324348 JupiterTestEngine engine = new JupiterTestEngine ();
0 commit comments