void () { myFixture.configureByText("a.java", """ class Singleton { boolean add(Object o) {} } class Usage { void foo() { Singleton.get<caret>Instance().add("a"); } } """); TemplateManagerImpl.setTemplateTesting(getTestRootDisposable()); doAction("Create method 'getInstance' in 'Singleton'"); final LookupEx lookup = LookupManager.getActiveLookup(getEditor()); final LookupElement item = (lookup == null ? null : lookup.getCurrentItem()); assertEquals("Singleton", (item == null ? null : item.getLookupString())); }