File tree Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -68,6 +68,10 @@ export interface File extends Suite {
6868 projectName : string | undefined
6969 collectDuration ?: number
7070 setupDuration ?: number
71+ /**
72+ * Whether the file is initiated without running any tests.
73+ */
74+ local ?: boolean
7175}
7276
7377export interface Test < ExtraContext = { } > extends TaskPopulated {
Original file line number Diff line number Diff line change @@ -69,14 +69,17 @@ export class StateManager {
6969 return Array . from ( this . pathsSet )
7070 }
7171
72+ /**
73+ * Return files that were running or collected.
74+ */
7275 getFiles ( keys ?: string [ ] ) : File [ ] {
7376 if ( keys ) {
7477 return keys
7578 . map ( key => this . filesMap . get ( key ) ! )
76- . filter ( Boolean )
7779 . flat ( )
80+ . filter ( file => file && ! file . local )
7881 }
79- return Array . from ( this . filesMap . values ( ) ) . flat ( )
82+ return Array . from ( this . filesMap . values ( ) ) . flat ( ) . filter ( file => ! file . local )
8083 }
8184
8285 getFilepaths ( ) : string [ ] {
@@ -128,6 +131,7 @@ export class StateManager {
128131 project . config . root ,
129132 project . config . name ,
130133 )
134+ fileTask . local = true
131135 this . idMap . set ( fileTask . id , fileTask )
132136 if ( ! files ) {
133137 this . filesMap . set ( path , [ fileTask ] )
You can’t perform that action at this time.
0 commit comments