Skip to content

Latest commit

 

History

History
52 lines (41 loc) · 3.25 KB

File metadata and controls

52 lines (41 loc) · 3.25 KB
Clean Architecture Toolkit for .NET
Clean Architecture Toolkit is a clean, modular architecture foundation for .NET applications.
It embraces SOLID principles and focuses on maintainability, testability, and scalability through clear boundaries and pluggable design.

|   HOME   |   REPO OVERVIEW   |   DEMO   |   CAT.UNITTESTING   |

Code Reference

UnitTestBase Class

Base class for a test fixture that needs a service provider. It builds the provider once per fixture from ConfigureServices(ServiceCollection) and disposes it after the last test.

public abstract class UnitTestBase

Inheritance System.Object → UnitTestBase

Fields
_serviceProvider
Properties
ServiceProvider The service provider of the fixture. It exists from the one time setup on.
Methods
BaseOneTimeSetup() Builds the service provider. NUnit runs it once before the first test of the fixture.
BaseOneTimeTearDown() Disposes the service provider. NUnit runs it once after the last test of the fixture.
ConfigureServices(ServiceCollection) Registers the services of the fixture.