Add incremental test.

This commit is contained in:
Cyrus Najmabadi
2014-12-09 17:45:50 -08:00
parent 666363a7de
commit 5b2778c200

View File

@@ -471,6 +471,16 @@ module ts {
compareTrees(oldText, newTextAndChange.text, newTextAndChange.textChangeRange, 0);
});
it('Contextual shift to generic invocation',() => {
var source = "var v = T>>(2)";
var index = source.indexOf('T');
var oldText = ScriptSnapshot.fromString(source);
var newTextAndChange = withInsert(oldText, index, "Foo<Bar<");
compareTrees(oldText, newTextAndChange.text, newTextAndChange.textChangeRange, 0);
});
// Simulated typing tests.
it('Type extends clause 1',() => {