BAEL-4492: Use the prefered List.toArray() approach (#9831)
This commit is contained in:
parent
696d707bd8
commit
d821719314
|
@ -32,7 +32,7 @@ public class JavaCollectionConversionUnitTest {
|
|||
@Test
|
||||
public final void givenUsingCoreJava_whenListConvertedToArray_thenCorrect() {
|
||||
final List<Integer> sourceList = Arrays.asList(0, 1, 2, 3, 4, 5);
|
||||
final Integer[] targetArray = sourceList.toArray(new Integer[sourceList.size()]);
|
||||
final Integer[] targetArray = sourceList.toArray(new Integer[0]);
|
||||
}
|
||||
|
||||
@Test
|
||||
|
|
Loading…
Reference in New Issue