additional checks and logging for iisx shutdown (#997)

This commit is contained in:
Andrew Stanton-Nurse 2017-03-30 11:48:24 -07:00 committed by GitHub
parent 4cdc970055
commit 7774ed50fa
1 changed files with 7 additions and 0 deletions

View File

@ -291,6 +291,13 @@ namespace Microsoft.AspNetCore.Server.IntegrationTesting
StopTimer();
}
// If by this point, the host process is still running (somehow), throw an error.
// A test failure is better than a silent hang and unknown failure later on
if(!_hostProcess.HasExited)
{
throw new Exception($"iisexpress Process {_hostProcess.Id} failed to shutdown");
}
}
}
}