Add incremental test.

This commit is contained in:
Cyrus Najmabadi 2014-12-09 17:18:18 -08:00
parent d549677911
commit 82098d1568

View File

@ -358,5 +358,15 @@ module ts {
compareTrees(oldText, newTextAndChange.text, newTextAndChange.textChangeRange, 0);
});
it('Parenthesized expression to arrow function',() => {
var source = "var v = (a, b, c, d, e)";
var index = source.indexOf('a');
var oldText = ScriptSnapshot.fromString(source);
var newTextAndChange = withInsert(oldText, index + 1, ":");
compareTrees(oldText, newTextAndChange.text, newTextAndChange.textChangeRange, -1);
});
});
}