From 6dc0005a43e919b1d179739af9071f7c2b5d2349 Mon Sep 17 00:00:00 2001 From: John Luo Date: Thu, 14 Apr 2016 11:36:02 -0700 Subject: [PATCH] Use UseServer() instead of UseKestrel() to allow override in tests --- test/ServerComparison.TestSites/Program.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/ServerComparison.TestSites/Program.cs b/test/ServerComparison.TestSites/Program.cs index d2256beb6f..65b7e9f3d5 100644 --- a/test/ServerComparison.TestSites/Program.cs +++ b/test/ServerComparison.TestSites/Program.cs @@ -10,7 +10,9 @@ namespace ServerComparison.TestSites public static void Main(string[] args) { var host = new WebHostBuilder() - .UseKestrel() + // We set the server by name before default args so that command line arguments can override it. + // This is used to allow deployers to choose the server for testing. + .UseServer("Microsoft.AspNetCore.Server.Kestrel") .UseDefaultHostingConfiguration(args) .UseIISIntegration() .UseStartup("ServerComparison.TestSites")