File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -126,6 +126,7 @@ export class RefactorProxy extends vscode.Disposable {
126126 this . _previousStdErrData = '' ;
127127 return ;
128128 }
129+ console . log ( `Refactor StdErr Out - ${ dataStr } ` ) ;
129130 let lengthOfHeader = dataStr . indexOf ( ':' ) + 1 ;
130131 let lengthOfMessage = parseInt ( dataStr . substring ( ERROR_PREFIX . length , lengthOfHeader - 1 ) ) ;
131132 if ( dataStr . length === lengthOfMessage + lengthOfHeader ) {
@@ -147,18 +148,21 @@ export class RefactorProxy extends vscode.Disposable {
147148 }
148149 }
149150 else {
151+ console . log ( `Initialize Failed - ${ dataStr } ` ) ;
150152 this . _initializeReject ( `Refactor failed. ${ dataStr } ` ) ;
151153 }
152154 }
153155 private handleError ( error : Error ) {
154156 if ( this . _startedSuccessfully ) {
157+ console . log ( `handleError after starting - ${ error + '' } ` ) ;
155158 return this . _commandReject ( error ) ;
156159 }
160+ console . log ( `handleError before starting - ${ error + '' } ` ) ;
157161 this . _initializeReject ( error ) ;
158162 }
159163 private onData ( data : string ) {
160164 if ( ! this . _commandResolve ) { return ; }
161-
165+ console . log ( 'onData - ' + data ) ;
162166 // Possible there was an exception in parsing the data returned
163167 // So append the data then parse it
164168 let dataStr = this . _previousOutData = this . _previousOutData + data + '' ;
Original file line number Diff line number Diff line change @@ -121,10 +121,14 @@ suite('Simple Refactor', () => {
121121 assert . equal ( textDocument . lineAt ( 234 ) . text . trim ( ) . endsWith ( '= "STARTED"' ) , true , 'Started Text Assigned to variable' ) ;
122122 assert . equal ( textDocument . lineAt ( 235 ) . text . indexOf ( '(newvariable' ) >= 0 , true , 'New Variable not being used' ) ;
123123 } ) . catch ( error => {
124+ console . log ( 'Catch Error:' + error ) ;
125+ console . log ( 'Output:' + ch . output ) ;
124126 assert . fail ( error + '' , null , 'Variable extraction failed\n' + ch . output ) ;
125127 } ) ;
126128 } , error => {
129+ console . log ( 'Error:' + error ) ;
130+ console . log ( 'Output:' + ch . output ) ;
127131 assert . fail ( error + '' , null , 'Variable extraction failed\n' + ch . output ) ;
128132 } ) ;
129- } ) ;
133+ } ) ;
130134} ) ;
You can’t perform that action at this time.
0 commit comments