Unit test failure; clearHostScreen function
This commit is contained in:
parent
a4f83b0835
commit
a389ff5f39
|
@ -302,9 +302,7 @@ namespace ts {
|
|||
// There is no extra check needed since we can just rely on the program to decide emit
|
||||
const builder = createBuilder({ getCanonicalFileName, computeHash });
|
||||
|
||||
if (watchingHost.system.clearScreen) {
|
||||
watchingHost.system.clearScreen();
|
||||
}
|
||||
clearHostScreen();
|
||||
reportWatchDiagnostic(createCompilerDiagnostic(Diagnostics.Starting_compilation_in_watch_mode));
|
||||
synchronizeProgram();
|
||||
|
||||
|
@ -496,10 +494,14 @@ namespace ts {
|
|||
scheduleProgramUpdate();
|
||||
}
|
||||
|
||||
function updateProgram() {
|
||||
function clearHostScreen() {
|
||||
if (watchingHost.system.clearScreen) {
|
||||
watchingHost.system.clearScreen();
|
||||
}
|
||||
}
|
||||
|
||||
function updateProgram() {
|
||||
clearHostScreen();
|
||||
|
||||
timerToUpdateProgram = undefined;
|
||||
reportWatchDiagnostic(createCompilerDiagnostic(Diagnostics.File_change_detected_Starting_incremental_compilation));
|
||||
|
|
|
@ -117,6 +117,10 @@ namespace ts.tscWatch {
|
|||
index++;
|
||||
});
|
||||
if (!skipWaiting) {
|
||||
if (errorsPosition === ExpectedOutputErrorsPosition.BeforeCompilationStarts) {
|
||||
assertWatchDiagnosticAt(host, index, ts.Diagnostics.Starting_compilation_in_watch_mode);
|
||||
index += 1;
|
||||
}
|
||||
assertWatchDiagnosticAt(host, index, Diagnostics.Compilation_complete_Watching_for_file_changes);
|
||||
}
|
||||
host.clearOutput();
|
||||
|
|
Loading…
Reference in a new issue