BigtableAsyncBufferedMutator implements AsyncBufferedMutator { @Override public void close() { flush(); try { helper.close(); } catch (IOException ioException) { throw new RuntimeException("could not close buffered mutator", ioException); } } BigtableAsyncBufferedMutator(
      BigtableApi bigtableApi, BigtableHBaseSettings settings, HBaseRequestAdapter adapter); @Override void close(); @Override void flush(); @Override Configuration getConfiguration(); @Override TableName getName(); @Override long getWriteBufferSize(); @Override List<CompletableFuture<Void>> mutate(List<? extends Mutation> mutations); @Override CompletableFuture<Void> mutate(final Mutation mutation);  }
@Test public void testClose() throws Exception { doNothing().when(mockBulkMutation).sendUnsent(); doNothing().when(mockBulkMutation).flush(); doNothing().when(mockBulkMutation).close(); asyncBufferedMutator.close(); verify(mockBulkMutation).sendUnsent(); verify(mockBulkMutation).flush(); verify(mockBulkMutation).close(); }