### Question:
Xs2aToSpiBulkPaymentMapper { public SpiBulkPayment mapToSpiBulkPayment(BulkPayment payment, String paymentProduct) { SpiBulkPayment bulk = new SpiBulkPayment(); bulk.setPaymentId(payment.getPaymentId()); bulk.setBatchBookingPreferred(payment.getBatchBookingPreferred()); bulk.setDebtorAccount(xs2aToSpiAccountReferenceMapper.mapToSpiAccountReference(payment.getDebtorAccount())); if (payment.getTransactionStatus() != null) { bulk.setPaymentStatus(payment.getTransactionStatus()); } bulk.setPaymentProduct(paymentProduct); bulk.setRequestedExecutionDate(payment.getRequestedExecutionDate()); bulk.setRequestedExecutionTime(payment.getRequestedExecutionTime()); bulk.setPayments(mapToListSpiSinglePayment(payment.getPayments(), paymentProduct)); bulk.setPsuDataList(xs2aToSpiPsuDataMapper.mapToSpiPsuDataList(payment.getPsuDataList())); bulk.setStatusChangeTimestamp(payment.getStatusChangeTimestamp()); bulk.setCreationTimestamp(payment.getCreationTimestamp()); bulk.setContentType(payment.getContentType()); bulk.setInstanceId(payment.getInstanceId()); return bulk; }  SpiBulkPayment mapToSpiBulkPayment(BulkPayment payment, String paymentProduct);  }### Answer:
@Test void mapToSpiBulkPaymentSuccess() { BulkPayment payment = buildBulkPayment(); SpiBulkPayment spiBulkPayment = xs2aToSpiBulkPaymentMapper.mapToSpiBulkPayment(payment, PAYMENT_PRODUCT); assertEquals(PAYMENT_ID, spiBulkPayment.getPaymentId()); assertTrue(spiBulkPayment.getBatchBookingPreferred()); assertEquals(buildSpiAccountReference(), spiBulkPayment.getDebtorAccount()); assertEquals(REQUESTED_EXECUTION_DATE, spiBulkPayment.getRequestedExecutionDate()); assertEquals(REQUESTED_EXECUTION_TIME, spiBulkPayment.getRequestedExecutionTime()); assertEquals(TRANSACTION_STATUS, spiBulkPayment.getPaymentStatus()); assertFalse(spiBulkPayment.getPayments().isEmpty()); assertEquals(PAYMENT_PRODUCT, spiBulkPayment.getPaymentProduct()); assertEquals(spiPsuDataList, spiBulkPayment.getPsuDataList()); assertEquals(STATUS_CHANGE_TIMESTAMP, spiBulkPayment.getStatusChangeTimestamp()); assertEquals(payment.getCreationTimestamp(), spiBulkPayment.getCreationTimestamp()); assertEquals(payment.getContentType(), spiBulkPayment.getContentType()); }