void () { LiveTemplateCompletionContributor.setShowTemplatesInTests(true, myFixture.getTestRootDisposable()); Registry.get("ide.completion.show.live.templates.on.top").setValue(true, myFixture.getTestRootDisposable()); myFixture.configureByText("a.java", "class Foo { ps<caret> } class psvClass {}"); type("v"); myFixture.assertPreferredCompletionItems(0, "psvm", "psvClass"); myFixture.configureByText("a.xml", "CARBON C<caret>"); myFixture.completeBasic(); myFixture.assertPreferredCompletionItems(0, "CD", "CARBON"); }