void () { myFixture.addClass("class Another {static int X = 123;}"); myFixture.configureByText("Test.java", """ class Test { void test() { Another.X = <caret>"xyz"; } }"""); IntentionAction action = myFixture.findSingleIntention("Change field 'X' type to 'String'"); assertNotNull(action); String text = IntentionPreviewPopupUpdateProcessor.getPreviewText(getProject(), action, getFile(), getEditor()); assertEquals("static String X = ...;", text); }