This repository contains the source code for a tutorial on how to write integration tests for minimal APIs using .NET 7, WebApplicationFactory, and XUnit. The tutorial can be found at Say Hello to Reliable Minimal APIs with Integration Tests.
The repository includes a minimal API project (MinimalApiDemo.Api) and an XUnit project for integration tests (MinimalApiDemo.Tests). The tests can be found in the TodoTests.cs file.
To run the code, you'll need to have the .NET 7 SDK installed on your machine. You can then clone the repository and run dotnet run from the MinimalApiDemo.Api directory.
To run the tests, navigate to the MinimalApiDemo.Tests directory and run dotnet test.
π Happy coding!