void () { Document document = FileDocumentManager.getInstance().getDocument(createLightFile()); assertNotNull(document); PsiJavaFile psiFile = (PsiJavaFile)PsiDocumentManager.getInstance(getProject()).getPsiFile(document); assertSame(document, PsiDocumentManager.getInstance(getProject()).getDocument(psiFile)); }