File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed
tests/cases/unittests/services Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -191,4 +191,22 @@ describe('Colorization', function () {
191
191
assert . equal ( results . finalEndOfLineState , ts . EndOfLineState . Start ) ;
192
192
} ) ;
193
193
} ) ;
194
+
195
+ describe ( "test cases for colorizing unterminted multi-line comment" , function ( ) {
196
+ it ( "unterminated multi-line comment correctelly" , function ( ) {
197
+ var results = getClassifications ( "/*" , ts . EndOfLineState . Start ) ;
198
+
199
+ assert . equal ( results . tuples . length , 1 ) ;
200
+ verifyClassification ( results . tuples [ 0 ] , 2 , ts . TokenClass . Comment ) ;
201
+ assert . equal ( results . finalEndOfLineState , ts . EndOfLineState . InMultiLineCommentTrivia ) ;
202
+ } ) ;
203
+
204
+ it ( "unterminated multi-line comment with trailing space correctelly" , function ( ) {
205
+ var results = getClassifications ( "/* " , ts . EndOfLineState . Start ) ;
206
+
207
+ assert . equal ( results . tuples . length , 1 ) ;
208
+ verifyClassification ( results . tuples [ 0 ] , 3 , ts . TokenClass . Comment ) ;
209
+ assert . equal ( results . finalEndOfLineState , ts . EndOfLineState . InMultiLineCommentTrivia ) ;
210
+ } ) ;
211
+ } ) ;
194
212
} ) ;
You can’t perform that action at this time.
0 commit comments