Merge branch 'master' into rootDir

This commit is contained in:
Sheetal Nandi
2019-10-17 12:54:26 -07:00
53 changed files with 10730 additions and 10292 deletions

View File

@@ -11,7 +11,7 @@ namespace ts {
verifyTsc({
scenario: "demo",
subScenario: "in master branch with everything setup correctly, reports no error",
subScenario: "in master branch with everything setup correctly and reports no error",
fs: () => projFs,
commandLineArgs: ["--b", "/src/tsconfig.json", "--verbose"]
});

View File

@@ -10,14 +10,14 @@ namespace ts {
verifyTsc({
scenario: "emptyFiles",
subScenario: "does not have empty files diagnostic when files is empty and references are provided",
subScenario: "has empty files diagnostic when files is empty and no references are provided",
fs: () => projFs,
commandLineArgs: ["--b", "/src/no-references"],
});
verifyTsc({
scenario: "emptyFiles",
subScenario: "has empty files diagnostic when files is empty and no references are provided",
subScenario: "does not have empty files diagnostic when files is empty and references are provided",
fs: () => projFs,
commandLineArgs: ["--b", "/src/with-references"],
});

View File

@@ -60,7 +60,7 @@ namespace ts {
sys.write(`${sys.getExecutingFilePath()} ${commandLineArgs.join(" ")}\n`);
sys.exit = exitCode => sys.exitCode = exitCode;
ts.executeCommandLine(
executeCommandLine(
sys,
{
onCompilerHostCreate: host => fakes.patchHostForBuildInfoReadWrite(host),

View File

@@ -37,6 +37,24 @@ namespace ts {
incrementalScenarios: [noChangeRun]
});
verifyTscIncrementalEdits({
scenario: "incremental",
subScenario: "with only dts files",
fs: () => loadProjectFromFiles({
"/src/project/src/main.d.ts": "export const x = 10;",
"/src/project/src/another.d.ts": "export const y = 10;",
"/src/project/tsconfig.json": "{}",
}),
commandLineArgs: ["--incremental", "--p", "src/project"],
incrementalScenarios: [
noChangeRun,
{
buildKind: BuildKind.IncrementalDtsUnchanged,
modifyFs: fs => appendText(fs, "/src/project/src/main.d.ts", "export const xy = 100;")
}
]
});
verifyTscIncrementalEdits({
scenario: "incremental",
subScenario: "when passing rootDir is in the tsconfig",