Skip to content
bitzorcas
EN

Guide

Running tests

How to run tests — CLI commands, running specific projects, test filters, and CI configuration.

Last updated

Prerequisites

  • .NET 10 SDK
  • Docker (for integration tests that need SQL Server + RabbitMQ)

Commands

Terminal window
# Run all tests
dotnet test
# Run specific project
dotnet test tests/BitzOrcas.Unit.Tests
dotnet test tests/BitzOrcas.Application.Tests
dotnet test tests/BitzOrcas.Architecture.Tests
# Run with filter
dotnet test --filter "FullyQualifiedName~NoteService"
# Run with detailed output
dotnet test --verbosity detailed
# Run with coverage
dotnet test --collect:"XPlat Code Coverage"
# Run specific framework
dotnet test --framework net10.0

Test projects

ProjectInfrastructure neededTypical duration
Unit.TestsNone< 1s
Application.TestsNone< 2s
Architecture.TestsNone< 1s
Integration.TestsDocker (SQL Server + RabbitMQ)5-30s
CodeGeneration.TestsNone< 2s

CI configuration

# GitHub Actions example
- name: Run tests
run: dotnet test --verbosity minimal --logger trx