### Question:
Xs2aToSpiPsuDataMapper { public List<SpiPsuData> mapToSpiPsuDataList(List<PsuIdData> psuIdDataList) { if (psuIdDataList == null) { return Collections.emptyList(); } return psuIdDataList.stream() .map(this::mapToSpiPsuData) .collect(Collectors.toList()); }  List<SpiPsuData> mapToSpiPsuDataList(List<PsuIdData> psuIdDataList); SpiPsuData mapToSpiPsuData(PsuIdData psuIdData);  }### Answer:
@Test void mapToSpiPsuDataList() { PsuIdData psuIdData = new PsuIdData(PSU_ID, PSU_ID_TYPE, PSU_CORPORATE_ID, PSU_CORPORATE_TYPE, PSU_IP_ADDRESS); SpiPsuData spiPsuDataExpected = buildSpiPsuDataWithoutAdditionalPsuData(); List<SpiPsuData> spiPsuDataListActual = xs2aToSpiPsuDataMapper.mapToSpiPsuDataList(Collections.singletonList(psuIdData)); assertNotNull(spiPsuDataListActual); assertFalse(spiPsuDataListActual.isEmpty()); Assertions.assertThat(spiPsuDataExpected).isEqualToComparingFieldByFieldRecursively(spiPsuDataListActual.get(0)); }
@Test void mapToSpiPsuDataList_psuIdDataListIsNull() { List<SpiPsuData> spiPsuDataListExpected = Collections.emptyList(); List<SpiPsuData> spiPsuDataListActual = xs2aToSpiPsuDataMapper.mapToSpiPsuDataList(null); assertNotNull(spiPsuDataListActual); assertEquals(spiPsuDataListExpected, spiPsuDataListActual); }