void () { myFixture.configureByFile("Intention.java"); AnnotateCapitalizationIntention intention = new AnnotateCapitalizationIntention(); assertTrue(intention.isAvailable(getProject(), getEditor(), getFile())); intention.invoke(getProject(), getEditor(), getFile()); NonBlockingReadActionImpl.waitForAsyncTaskCompletion(); myFixture.checkResultByFile("Intention_after.java"); assertFalse(intention.isAvailable(getProject(), getEditor(), getFile())); }