Set ShutdownTimeout in Kestrel tests (#25743)
This commit is contained in:
parent
a7d129cc97
commit
2ab6436cdd
|
|
@ -101,6 +101,13 @@ namespace Microsoft.AspNetCore.Server.Kestrel.FunctionalTests
|
||||||
.UseSetting(WebHostDefaults.ShutdownTimeoutKey, TestConstants.DefaultTimeout.TotalSeconds.ToString())
|
.UseSetting(WebHostDefaults.ShutdownTimeoutKey, TestConstants.DefaultTimeout.TotalSeconds.ToString())
|
||||||
.Configure(app => { app.Run(_app); });
|
.Configure(app => { app.Run(_app); });
|
||||||
})
|
})
|
||||||
|
.ConfigureServices(services =>
|
||||||
|
{
|
||||||
|
services.Configure<HostOptions>(option =>
|
||||||
|
{
|
||||||
|
option.ShutdownTimeout = TestConstants.DefaultTimeout;
|
||||||
|
});
|
||||||
|
})
|
||||||
.Build();
|
.Build();
|
||||||
|
|
||||||
_host.Start();
|
_host.Start();
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue