void () { try { doTest(() -> { final PsiClass srcClass = myFixture.findClass("a.A"); myFixture.findClass("b.B"); final PsiField[] fields = srcClass.getFields(); assertTrue("No methods found", fields.length > 0); final MemberInfo memberInfo = new MemberInfo(fields[0]); memberInfo.setChecked(true); new PushDownProcessor<>(srcClass, Collections.singletonList(memberInfo), new DocCommentPolicy(DocCommentPolicy.ASIS)).run(); //LocalFileSystem.getInstance().refresh(false); //FileDocumentManager.getInstance().saveAllDocuments(); }); } catch (BaseRefactoringProcessor.ConflictsInTestsException e) { assertEquals(e.getMessage(), "Class <b><code>b.B</code></b> is package-private and will not be accessible from file <b><code>A.form</code></b>."); return; } fail("Conflict was not detected"); }