BackupCursors implements Iterator<BackupCursors.CursorAndType> { @Override public void remove() { throw new UnsupportedOperationException(); } BackupCursors(); int count(); int count(DataType type); @Override boolean hasNext(); @Override CursorAndType next(); @Override void remove(); void close();  }
@Test(expected = UnsupportedOperationException.class) public void shouldNotSupportRemove() throws Exception { cursors.remove(); }