IDEA-81062 During typing of Live Template prefix top element at lookup must be selected.

This commit is contained in:
peter
2012-04-24 18:48:59 +02:00
parent 6b6f1b5810
commit 875d81df05
2 changed files with 7 additions and 2 deletions
@@ -310,9 +310,14 @@ public class LiveTemplateTest extends LightCodeInsightFixtureTestCase {
myFixture.type('it')
assert myFixture.lookupElementStrings[0].startsWith('it')
assert LookupManager.getInstance(project).activeLookup.currentItem == myFixture.getLookupElements()[0]
myFixture.type('e')
assert myFixture.lookupElementStrings[0].startsWith('ite')
assert LookupManager.getInstance(project).activeLookup.currentItem == myFixture.getLookupElements()[0]
LookupManager.getInstance(project).hideActiveLookup()
myFixture.type('\b')
myFixture.type('\b\b')
new ListTemplatesHandler().invoke(project, editor, myFixture.file);
assert myFixture.lookupElementStrings.containsAll(['iter', 'itco'])
LookupManager.getInstance(project).hideActiveLookup()