Test transitive references in folders side by side so that later we can add tsserver tests as well

This commit is contained in:
Sheetal Nandi
2018-10-04 11:41:53 -07:00
parent 3e67cf43b0
commit 2fb11d8530
3 changed files with 234 additions and 161 deletions

View File

@@ -925,8 +925,8 @@ namespace ts.server {
const newFile = this.program.getSourceFileByPath(f.resolvedPath);
if (!newFile || (f.resolvedPath === f.path && newFile.resolvedPath !== f.path)) {
// new program does not contain this file - detach it from the project
// - remove resolutions only if this is undirected file or doesnt have source file with the path in new program
this.detachScriptInfoFromProject(f.fileName, f.path !== f.resolvedPath && !!this.program.getSourceFileByPath(f.path));
// - remove resolutions only if the new program doesnt contain source file by the path (not resolvedPath since path is used for resolution)
this.detachScriptInfoFromProject(f.fileName, !!this.program.getSourceFileByPath(f.path));
}
}