@@ -14,6 +14,7 @@ import { noop } from '../../client/common/core.utils';
14
14
import { IS_WINDOWS } from '../../client/common/platform/constants' ;
15
15
import { FileSystem } from '../../client/common/platform/fileSystem' ;
16
16
import { PlatformService } from '../../client/common/platform/platformService' ;
17
+ import { StopWatch } from '../../client/common/stopWatch' ;
17
18
import { DebugOptions , LaunchRequestArguments } from '../../client/debugger/Common/Contracts' ;
18
19
import { sleep } from '../common' ;
19
20
import { IS_MULTI_ROOT_TEST , TEST_DEBUGGER } from '../initialize' ;
@@ -447,34 +448,35 @@ let testCounter = 0;
447
448
await debugClient . assertStoppedLocation ( 'exception' , pauseLocation ) ;
448
449
} ) ;
449
450
test ( 'Test multi-threaded debugging' , async ( ) => {
450
- console . log ( 'step1' ) ;
451
+ const stopWatch = new StopWatch ( ) ;
452
+ console . log ( `step1 ${ stopWatch . elapsedTime } ` ) ;
451
453
await Promise . all ( [
452
454
debugClient . configurationSequence ( ) ,
453
455
debugClient . launch ( buildLauncArgs ( 'multiThread.py' , false ) ) ,
454
456
debugClient . waitForEvent ( 'initialized' )
455
457
] ) ;
456
458
debugClient . addListener ( 'output' , output => {
457
- console . log ( JSON . stringify ( output ) ) ;
459
+ console . log ( `stepx ${ stopWatch . elapsedTime } , ${ JSON . stringify ( output ) } ` ) ;
458
460
} ) ;
459
- console . log ( ' step2' ) ;
461
+ console . log ( ` step2 ${ stopWatch . elapsedTime } ` ) ;
460
462
const pythonFile = path . join ( debugFilesPath , 'multiThread.py' ) ;
461
463
const breakpointLocation = { path : pythonFile , column : 1 , line : 15 } ;
462
464
await debugClient . setBreakpointsRequest ( {
463
465
lines : [ breakpointLocation . line ] ,
464
466
breakpoints : [ { line : breakpointLocation . line , column : breakpointLocation . column } ] ,
465
467
source : { path : breakpointLocation . path }
466
468
} ) ;
467
- console . log ( ' step3' ) ;
469
+ console . log ( ` step3 ${ stopWatch . elapsedTime } ` ) ;
468
470
// hit breakpoint.
469
471
await debugClient . assertStoppedLocation ( 'breakpoint' , breakpointLocation ) ;
470
- console . log ( ' step4' ) ;
472
+ console . log ( ` step4 ${ stopWatch . elapsedTime } ` ) ;
471
473
const threads = await debugClient . threadsRequest ( ) ;
472
- console . log ( ' step5' ) ;
474
+ console . log ( ` step5 ${ stopWatch . elapsedTime } ` ) ;
473
475
expect ( threads . body . threads ) . of . lengthOf ( 2 , 'incorrect number of threads' ) ;
474
476
for ( const thread of threads . body . threads ) {
475
477
expect ( thread . id ) . to . be . lessThan ( MAX_SIGNED_INT32 + 1 , 'ThreadId is not an integer' ) ;
476
478
}
477
- console . log ( ' step6' ) ;
479
+ console . log ( ` step6 ${ stopWatch . elapsedTime } ` ) ;
478
480
} ) ;
479
481
test ( 'Test stack frames' , async ( ) => {
480
482
await Promise . all ( [
0 commit comments