dotnet test
The dotnet command that builds test projects and runs their tests, reporting passes and failures.
In more detail
It prints a summary of passed, failed and skipped tests and exits with a failure code if any test fails. Continuous integration runs it for the whole solution on every change; --no-restore skips a restore already done.
Example
dotnet test --no-restoreRelated terms
- xUnit.net — A popular open-source unit testing framework for .NET, where [Fact] marks a test method and Assert checks results.
- unit test — An automated check of one small piece of code, such as a single function, that runs quickly and on its own.
- continuous integration — Automatically building and testing every change as soon as it is pushed, so problems are caught early.
Taught in
- Unit Testing with xUnit and NSubstitute — Modern .NET Core, C# & Enterprise Microservices
- Integration Testing with WebApplicationFactory — Modern .NET Core, C# & Enterprise Microservices
- Behavior-Driven Development with Reqnroll — Modern .NET Core, C# & Enterprise Microservices
- OpenTelemetry, Container Publishing and Trimming — Modern .NET Core, C# & Enterprise Microservices