@@ -23,6 +23,8 @@ interface CachedConfigSet {
2323 jestConfig : JsonableValue < ProjectConfigTsJest >
2424 transformerCfgStr : string
2525 compiler : TsJestCompiler
26+ depGraphs : Map < string , DepGraphInfo >
27+ tsResolvedModulesCachePath : string | undefined
2628}
2729
2830interface TsJestHooksMap {
@@ -65,6 +67,8 @@ export class TsJestTransformer implements Transformer {
6567 if ( ccs ) {
6668 this . _transformCfgStr = ccs . transformerCfgStr
6769 this . _compiler = ccs . compiler
70+ this . _depGraphs = ccs . depGraphs
71+ this . _tsResolvedModulesCachePath = ccs . tsResolvedModulesCachePath
6872 configSet = ccs . configSet
6973 } else {
7074 // try to look-it up by stringified version
@@ -79,6 +83,8 @@ export class TsJestTransformer implements Transformer {
7983 serializedCcs . jestConfig . value = config
8084 this . _transformCfgStr = serializedCcs . transformerCfgStr
8185 this . _compiler = serializedCcs . compiler
86+ this . _depGraphs = serializedCcs . depGraphs
87+ this . _tsResolvedModulesCachePath = serializedCcs . tsResolvedModulesCachePath
8288 configSet = serializedCcs . configSet
8389 } else {
8490 // create the new record in the index
@@ -92,13 +98,15 @@ export class TsJestTransformer implements Transformer {
9298 jest . cacheDirectory = undefined as any
9399 this . _transformCfgStr = `${ new JsonableValue ( jest ) . serialized } ${ configSet . cacheSuffix } `
94100 this . _compiler = new TsJestCompiler ( configSet , cacheFS )
101+ this . _getFsCachedResolvedModules ( configSet )
95102 TsJestTransformer . _cachedConfigSets . push ( {
96103 jestConfig : new JsonableValue ( config ) ,
97104 configSet,
98105 transformerCfgStr : this . _transformCfgStr ,
99106 compiler : this . _compiler ,
107+ depGraphs : this . _depGraphs ,
108+ tsResolvedModulesCachePath : this . _tsResolvedModulesCachePath ,
100109 } )
101- this . _getFsCachedResolvedModules ( configSet )
102110 }
103111 }
104112
0 commit comments