Merge pull request #27139 from ajafff/config-extends

fix getExtendedConfig in commandLineParser
This commit is contained in:
Ryan Cavanaugh authored and GitHub committed 2018-09-17 16:29:16 -07:00
commit 577ee49106
2 files changed
+19 -5

No files matched your search

@@ -244,6 +244,20 @@ namespace ts {
}, [
combinePaths(basePath, "main.ts")
]);
it("adds extendedSourceFiles only once", () => {
const sourceFile = readJsonConfigFile("configs/fourth.json", (path) => host.readFile(path));
const dir = combinePaths(basePath, "configs");
const expected = [
combinePaths(dir, "third.json"),
combinePaths(dir, "second.json"),
combinePaths(dir, "base.json"),
];
parseJsonSourceFileConfigFileContent(sourceFile, host, dir, {}, "fourth.json");
assert.deepEqual(sourceFile.extendedSourceFiles, expected);
parseJsonSourceFileConfigFileContent(sourceFile, host, dir, {}, "fourth.json");
assert.deepEqual(sourceFile.extendedSourceFiles, expected);
});
});
});
});