@Test public void onFunded() { final RequestFundedEvent fundedEvent = RequestFundedEvent.builder() .fundDto(FundDtoMother.aFundDto().build()) .timestamp(LocalDateTime.now()) .requestId(35L).build(); final RequestFundedNotificationDto expected = RequestFundedNotificationDto.builder() .blockchainEventId(fundedEvent.getFundDto().getBlockchainEventId()) .date(fundedEvent.getTimestamp()) .requestId(fundedEvent.getRequestId()) .fundId(fundedEvent.getFundDto().getId()) .build(); eventHandler.onFunded(fundedEvent); verify(applicationEventPublisher).publishEvent(refEq(expected, "uuid")); }
@TransactionalEventListener public void onFunded(final RequestFundedEvent fundedEvent) { eventPublisher.publishEvent(new RequestFundedNotificationDto(fundedEvent.getFundDto().getBlockchainEventId(), fundedEvent.getTimestamp(), fundedEvent.getRequestId(), fundedEvent.getFundDto().getId())); }
PublishRequestFundedNotificationHandler { @TransactionalEventListener public void onFunded(final RequestFundedEvent fundedEvent) { eventPublisher.publishEvent(new RequestFundedNotificationDto(fundedEvent.getFundDto().getBlockchainEventId(), fundedEvent.getTimestamp(), fundedEvent.getRequestId(), fundedEvent.getFundDto().getId())); } }
PublishRequestFundedNotificationHandler { @TransactionalEventListener public void onFunded(final RequestFundedEvent fundedEvent) { eventPublisher.publishEvent(new RequestFundedNotificationDto(fundedEvent.getFundDto().getBlockchainEventId(), fundedEvent.getTimestamp(), fundedEvent.getRequestId(), fundedEvent.getFundDto().getId())); } PublishRequestFundedNotificationHandler(final ApplicationEventPublisher eventPublisher); }
PublishRequestFundedNotificationHandler { @TransactionalEventListener public void onFunded(final RequestFundedEvent fundedEvent) { eventPublisher.publishEvent(new RequestFundedNotificationDto(fundedEvent.getFundDto().getBlockchainEventId(), fundedEvent.getTimestamp(), fundedEvent.getRequestId(), fundedEvent.getFundDto().getId())); } PublishRequestFundedNotificationHandler(final ApplicationEventPublisher eventPublisher); @TransactionalEventListener void onFunded(final RequestFundedEvent fundedEvent); }
PublishRequestFundedNotificationHandler { @TransactionalEventListener public void onFunded(final RequestFundedEvent fundedEvent) { eventPublisher.publishEvent(new RequestFundedNotificationDto(fundedEvent.getFundDto().getBlockchainEventId(), fundedEvent.getTimestamp(), fundedEvent.getRequestId(), fundedEvent.getFundDto().getId())); } PublishRequestFundedNotificationHandler(final ApplicationEventPublisher eventPublisher); @TransactionalEventListener void onFunded(final RequestFundedEvent fundedEvent);  }