TAF.Infra.TestKit 1.0.0

dotnet add package TAF.Infra.TestKit --version 1.0.0
                    
NuGet\Install-Package TAF.Infra.TestKit -Version 1.0.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="TAF.Infra.TestKit" Version="1.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="TAF.Infra.TestKit" Version="1.0.0" />
                    
Directory.Packages.props
<PackageReference Include="TAF.Infra.TestKit" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add TAF.Infra.TestKit --version 1.0.0
                    
#r "nuget: TAF.Infra.TestKit, 1.0.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package TAF.Infra.TestKit@1.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=TAF.Infra.TestKit&version=1.0.0
                    
Install as a Cake Addin
#tool nuget:?package=TAF.Infra.TestKit&version=1.0.0
                    
Install as a Cake Tool

TAF.Infra.TestKit

Phase-1 (no-DB) unit-test foundation shared by every TAF service's *.UnitTests project.

What's in it

Area Type Purpose
Context/ BusContextBuilder Fluent BusContext (TenantId / AppId / UserId / EnvironmentId / CorrelationId) with deterministic defaults.
Builders/ AppObjectBuilder, FieldBuilder In-memory AppObject / FieldDefinition metadata (types live in TAF.Infra.Contract.Models).
Assertions/ OperationResultAssertions ShouldBeSuccess / ShouldBeFailure / ShouldBeFailureWithCode over the OperationResult pattern.
Fakes/ BusFakes NSubstitute fakes for ICommandBus / IQueryBus.
TestIds static Single source of deterministic Guids used by the builders.

Test stack (Phase 1)

xUnit · AwesomeAssertions (not FluentAssertions) · NSubstitute (not Moq) · Bogus · coverlet.collector. No DB / HTTP / Testcontainers / Respawn / WebApplicationFactory — those are deferred to an integration phase.

Distribution & consumption

TAF.Infra.TestKit is packaged as a NuGet package (like every other TAF.Infra.* library) and referenced by service test projects via <PackageReference Include="TAF.Infra.TestKit" Version="1.0.0" />. AwesomeAssertions / NSubstitute / Bogus flow transitively, so a consuming *.UnitTests project only needs this package plus xUnit + the test SDK + coverlet.

Why not domain (e.g. permission) builders here? taf_infra cannot reference service-owned domain types (that would invert the Clean-Architecture dependency flow). Service-specific builders/assertions (e.g. PermissionBuilder, AssertAllows/AssertDenies/AssertScope for the identity bitwise model) live in that service's own test project.

Central package management & coverage

Each service repo carries a tests/Directory.Packages.props (CPM versions) and tests/Directory.Build.props (coverlet collector + coverage exclusions) scoped to the tests/ folder, so production projects — which use inline package versions — are never forced under CPM.

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on TAF.Infra.TestKit:

Package Downloads
TAF.Infra.TestKit.Integration

Phase-2 integration-test foundation for the TAF platform: a Testcontainers-backed Postgres fixture, Respawn-based reset-between-tests, and WebApplicationFactory config-override helpers. Deliberately a SEPARATE package from TAF.Infra.TestKit -- that package is referenced by every service's *.UnitTests project today and is documented as having no DB/HTTP/container dependencies; this package carries those heavier dependencies so only *.IntegrationTests projects that actually need them pull them in.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.0 642 6/22/2026