Add test for jsdoc syntactic classification for function declaration

This commit is contained in:
zhengbli 2016-08-20 20:41:33 -07:00
Родитель d24afc2ad0
Коммит e445e012c4
1 изменённых файлов: 24 добавлений и 0 удалений

Просмотреть файл

@ -0,0 +1,24 @@
/// <reference path="fourslash.ts"/>
//// /** @param {number} p1 */
//// function foo(p1) {}
var c = classification;
verify.syntacticClassificationsAre(
c.comment("/** "),
c.punctuation("@"),
c.docCommentTagName("param"),
c.comment(" "),
c.punctuation("{"),
c.keyword("number"),
c.punctuation("}"),
c.comment(" "),
c.parameterName("p1"),
c.comment(" */"),
c.keyword("function"),
c.identifier("foo"),
c.punctuation("("),
c.parameterName("p1"),
c.punctuation(")"),
c.punctuation("{"),
c.punctuation("}"));