Skip to content

Commit 43ae480

Browse files
TestServer comes in a package (#18969)
1 parent 80446f1 commit 43ae480

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

aspnetcore/test/middleware.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,14 @@ In the test project, create a test:
3030

3131
* Build and start a host that uses <xref:Microsoft.AspNetCore.TestHost.TestServer>.
3232
* Add any required services that the middleware uses.
33+
* Add the [Microsoft.AspNetCore.TestHost](https://www.nuget.org/packages/Microsoft.AspNetCore.TestHost/) NuGet package to the project:
34+
35+
```dotnetcli
36+
<ItemGroup>
37+
<PackageReference Include="Microsoft.AspNetCore.TestHost" Version="3.1.*" />
38+
</ItemGroup>
39+
```
40+
3341
* Configure the processing pipeline to use the middleware for the test.
3442

3543
[!code-csharp[](middleware/samples_snapshot/3.x/setup.cs?highlight=4-18)]

0 commit comments

Comments
 (0)