@Test public void cancelWithDelegation() throws Exception { mTestStream.write(BufferUtils.getIncreasingByteArray((int) (BLOCK_LENGTH * 1.5))); mTestStream.cancel(); for (long streamIndex = 0; streamIndex < 2; streamIndex++) { assertTrue(mAlluxioOutStreamMap.get(streamIndex).isClosed()); assertTrue(mAlluxioOutStreamMap.get(streamIndex).isCanceled()); } verify(mFileSystemMasterClient, times(0)).completeFile(any(AlluxioURI.class), any(CompleteFilePOptions.class)); }
@Override public void cancel() throws IOException {}
FileOutStream extends OutputStream implements Cancelable { @Override public void cancel() throws IOException {} }
FileOutStream extends OutputStream implements Cancelable { @Override public void cancel() throws IOException {}  }
FileOutStream extends OutputStream implements Cancelable { @Override public void cancel() throws IOException {}  @Deprecated int getBytesWritten(); @Override void cancel(); }
FileOutStream extends OutputStream implements Cancelable { @Override public void cancel() throws IOException {}  @Deprecated int getBytesWritten(); @Override void cancel();  }