void (@NotNull JTree tree, @NotNull List<TreePath> list, @NotNull Runnable task) { Iterator<TreePath> iterator = list.iterator(); forEachRow(tree, path -> { assertTrue(iterator.hasNext()); assertTreePath(path, iterator.next()); }); assertFalse(iterator.hasNext()); task.run(); }