@@ -63,7 +63,7 @@ suite('Autocomplete', () => {
6363 return vscode . window . showTextDocument ( textDocument ) ;
6464 } ) . then ( editor => {
6565 textEditor = editor ;
66- const position = new vscode . Position ( 30 , 10 ) ;
66+ const position = new vscode . Position ( 30 , 4 ) ;
6767 return vscode . commands . executeCommand ( 'vscode.executeCompletionItemProvider' , textDocument . uri , position ) ;
6868 } ) . then ( ( list : { isIncomplete : boolean , items : vscode . CompletionItem [ ] } ) => {
6969 assert . notEqual ( list . items . filter ( item => item . label === 'description' ) . length , 0 , 'description not found' ) ;
@@ -134,12 +134,12 @@ suite('Code Definition', () => {
134134 return vscode . window . showTextDocument ( textDocument ) ;
135135 } ) . then ( editor => {
136136 textEditor = editor ;
137- const position = new vscode . Position ( 30 , 12 ) ;
137+ const position = new vscode . Position ( 30 , 5 ) ;
138138 return vscode . commands . executeCommand ( 'vscode.executeDefinitionProvider' , textDocument . uri , position ) ;
139139 } ) . then ( ( def : [ { range : vscode . Range , uri : vscode . Uri } ] ) => {
140140 assert . equal ( def . length , 1 , 'Definition lenght is incorrect' ) ;
141- assert . equal ( `${ def [ 0 ] . range . start . line } ,${ def [ 0 ] . range . start . character } ` , '10,4 ' , 'Start position is incorrect' ) ;
142- assert . equal ( `${ def [ 0 ] . range . end . line } ,${ def [ 0 ] . range . end . character } ` , '10,4 ' , 'End position is incorrect' ) ;
141+ assert . equal ( `${ def [ 0 ] . range . start . line } ,${ def [ 0 ] . range . start . character } ` , '17,8 ' , 'Start position is incorrect' ) ;
142+ assert . equal ( `${ def [ 0 ] . range . end . line } ,${ def [ 0 ] . range . end . character } ` , '17,8 ' , 'End position is incorrect' ) ;
143143 } ) . then ( done , done ) ;
144144 } ) ;
145145
@@ -221,12 +221,12 @@ suite('Hover Definition', () => {
221221 return vscode . window . showTextDocument ( textDocument ) ;
222222 } ) . then ( editor => {
223223 textEditor = editor ;
224- const position = new vscode . Position ( 31 , 14 ) ;
224+ const position = new vscode . Position ( 30 , 5 ) ;
225225 return vscode . commands . executeCommand ( 'vscode.executeHoverProvider' , textDocument . uri , position ) ;
226226 } ) . then ( ( def : [ { range : vscode . Range , contents : { language : string , value : string } [ ] } ] ) => {
227227 assert . equal ( def . length , 1 , 'Definition lenght is incorrect' ) ;
228- assert . equal ( `${ def [ 0 ] . range . start . line } ,${ def [ 0 ] . range . start . character } ` , '31,10 ' , 'Start position is incorrect' ) ;
229- assert . equal ( `${ def [ 0 ] . range . end . line } ,${ def [ 0 ] . range . end . character } ` , '31,17 ' , 'End position is incorrect' ) ;
228+ assert . equal ( `${ def [ 0 ] . range . start . line } ,${ def [ 0 ] . range . start . character } ` , '30,4 ' , 'Start position is incorrect' ) ;
229+ assert . equal ( `${ def [ 0 ] . range . end . line } ,${ def [ 0 ] . range . end . character } ` , '30,11 ' , 'End position is incorrect' ) ;
230230 assert . equal ( def [ 0 ] . contents . length , 1 , 'Invalid content items' ) ;
231231 assert . equal ( def [ 0 ] . contents [ 0 ] . value , `method1(self)${ EOL } ${ EOL } This is method1` , 'Invalid conents' ) ;
232232 } ) . then ( done , done ) ;
0 commit comments