void () { doTest(() -> { PsiClass superClass = myFixture.findClass("Superclass"); ApplicationManager.getApplication().invokeLater( () -> CreateSubclassAction.createSameFileClass("Subclass", superClass)); UIUtil.dispatchAllInvocationEvents(); }); }