StandardTransferListenerSupport implements TransferListenerSupport { @Override public void fireTransferProgress(Resource resource, int requestType, byte[] buffer, int length) { TransferEvent event = new TransferEvent(this.wagon, resource, TransferEvent.TRANSFER_PROGRESS, requestType); for (TransferListener transferListener : this.transferListeners) { transferListener.transferProgress(event, buffer, length); } } StandardTransferListenerSupport(Wagon wagon); @Override void addTransferListener(TransferListener transferListener); @Override void removeTransferListener(TransferListener transferListener); @Override boolean hasTransferListener(TransferListener transferListener); @Override void fireTransferInitiated(Resource resource, int requestType); @Override void fireTransferStarted(Resource resource, int requestType); @Override void fireTransferProgress(Resource resource, int requestType, byte[] buffer, int length); @Override void fireTransferCompleted(Resource resource, int requestType); @Override void fireTransferError(Resource resource, int requestType, Exception exception);  }
@Test public void fireTransferProgress() { byte[] buffer = new byte[0]; int length = 0; this.transferListenerSupport.fireTransferProgress(this.resource, REQUEST_TYPE, buffer, length); verify(this.transferListener).transferProgress( eq(new TransferEvent(this.wagon, this.resource, TransferEvent.TRANSFER_PROGRESS, REQUEST_TYPE)), Matchers.eq(buffer), Matchers.eq(length)); }