void (@NotNull ProgressIndicator indicator) { ApplicationManager.getApplication().assertIsNonDispatchThread(); Semaphore local = new Semaphore(1); vDir2.refresh(true, true, () -> { log.add("modal finished"); local.up(); }); assertTrue(local.waitFor(10_000)); assertThat(vDir2.getChildren()).hasSize(1); }