|
|
@ -124,8 +124,8 @@ public class DownloadReceiptsStepTest { |
|
|
|
PeerTaskExecutorResult<Map<BlockHeader, List<TransactionReceipt>>> peerTaskResult = |
|
|
|
PeerTaskExecutorResult<Map<BlockHeader, List<TransactionReceipt>>> peerTaskResult = |
|
|
|
new PeerTaskExecutorResult<>( |
|
|
|
new PeerTaskExecutorResult<>( |
|
|
|
Optional.of(receiptsMap), PeerTaskExecutorResponseCode.SUCCESS); |
|
|
|
Optional.of(receiptsMap), PeerTaskExecutorResponseCode.SUCCESS); |
|
|
|
Mockito.when(peerTaskExecutor.executeAsync(Mockito.any(GetReceiptsFromPeerTask.class))) |
|
|
|
Mockito.when(peerTaskExecutor.execute(Mockito.any(GetReceiptsFromPeerTask.class))) |
|
|
|
.thenReturn(CompletableFuture.completedFuture(peerTaskResult)); |
|
|
|
.thenReturn(peerTaskResult); |
|
|
|
|
|
|
|
|
|
|
|
final CompletableFuture<List<BlockWithReceipts>> result = downloadReceiptsStep.apply(blocks); |
|
|
|
final CompletableFuture<List<BlockWithReceipts>> result = downloadReceiptsStep.apply(blocks); |
|
|
|
|
|
|
|
|
|
|
|