@@ -670,12 +670,24 @@ export class TestControllerManager {
670670 await DebugManager . runTests ( workspace , [ ] , [ ] , [ ] , runId , options , dryRun ) ;
671671 } else {
672672 const includedInWs = testItems
673- . map ( ( i ) => this . findRobotItem ( i ) ?. longname )
673+ . map ( ( i ) => {
674+ const ritem = this . findRobotItem ( i ) ;
675+ if ( ritem ?. type == "workspace" && ritem . children ?. length ) {
676+ return ritem . children [ 0 ] . longname ;
677+ }
678+ return ritem ?. longname ;
679+ } )
674680 . filter ( ( i ) => i !== undefined ) as string [ ] ;
675681 const excludedInWs =
676682 ( excluded
677683 . get ( workspace )
678- ?. map ( ( i ) => this . findRobotItem ( i ) ?. longname )
684+ ?. map ( ( i ) => {
685+ const ritem = this . findRobotItem ( i ) ;
686+ if ( ritem ?. type == "workspace" && ritem . children ?. length ) {
687+ return ritem . children [ 0 ] . longname ;
688+ }
689+ return ritem ?. longname ;
690+ } )
679691 . filter ( ( i ) => i !== undefined ) as string [ ] ) ?? [ ] ;
680692
681693 const suites = new Set < string > ( ) ;
@@ -687,7 +699,11 @@ export class TestControllerManager {
687699 if ( longname ) suites . add ( longname ) ;
688700 }
689701 } else {
690- const longname = this . findRobotItem ( testItem ) ?. longname ;
702+ const ritem = this . findRobotItem ( testItem ) ;
703+ let longname = ritem ?. longname ;
704+ if ( ritem ?. type == "workspace" && ritem . children ?. length ) {
705+ longname = ritem . children [ 0 ] . longname ;
706+ }
691707 if ( longname ) suites . add ( longname ) ;
692708 }
693709 }
0 commit comments