private void doTest(String infoText, int highlightedParameterIndex) throws Exception {
configureByFile(getTestName(false) + "." + DartFileType.DEFAULT_EXTENSION);
final DartParameterInfoHandler parameterInfoHandler = new DartParameterInfoHandler();
MockCreateParameterInfoContext createContext = new MockCreateParameterInfoContext(myEditor, myFile);
PsiElement elt = parameterInfoHandler.findElementForParameterInfo(createContext);
assertNotNull(elt);
parameterInfoHandler.showParameterInfo(elt, createContext);
Object[] items = createContext.getItemsToShow();
assertTrue(items != null);
assertTrue(items.length > 0);
MockParameterInfoUIContext context = new MockParameterInfoUIContext<PsiElement>(elt);
parameterInfoHandler.updateUI((DartFunctionDescription)items[0], context);
assertEquals(infoText, parameterInfoHandler.myParametersListPresentableText);