From 43ae480ffc8ed0095dd42d88ca801c20b33d8e5e Mon Sep 17 00:00:00 2001 From: Rick Anderson <3605364+Rick-Anderson@users.noreply.github.com> Date: Thu, 25 Jun 2020 14:41:15 -1000 Subject: [PATCH] TestServer comes in a package (#18969) --- aspnetcore/test/middleware.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/aspnetcore/test/middleware.md b/aspnetcore/test/middleware.md index 25bfafbec6..fc845b7e60 100644 --- a/aspnetcore/test/middleware.md +++ b/aspnetcore/test/middleware.md @@ -30,6 +30,14 @@ In the test project, create a test: * Build and start a host that uses . * Add any required services that the middleware uses. +* Add the [Microsoft.AspNetCore.TestHost](https://www.nuget.org/packages/Microsoft.AspNetCore.TestHost/) NuGet package to the project: + + ```dotnetcli + + + + ``` + * Configure the processing pipeline to use the middleware for the test. [!code-csharp[](middleware/samples_snapshot/3.x/setup.cs?highlight=4-18)]