Rig.TUnit.Databases
0.0.0-alpha.0.14
See the version list below for details.
dotnet add package Rig.TUnit.Databases --version 0.0.0-alpha.0.14
NuGet\Install-Package Rig.TUnit.Databases -Version 0.0.0-alpha.0.14
<PackageReference Include="Rig.TUnit.Databases" Version="0.0.0-alpha.0.14" />
<PackageVersion Include="Rig.TUnit.Databases" Version="0.0.0-alpha.0.14" />
<PackageReference Include="Rig.TUnit.Databases" />
paket add Rig.TUnit.Databases --version 0.0.0-alpha.0.14
#r "nuget: Rig.TUnit.Databases, 0.0.0-alpha.0.14"
#:package Rig.TUnit.Databases@0.0.0-alpha.0.14
#addin nuget:?package=Rig.TUnit.Databases&version=0.0.0-alpha.0.14&prerelease
#tool nuget:?package=Rig.TUnit.Databases&version=0.0.0-alpha.0.14&prerelease
Rig.TUnit
A TUnit-first integration-testing rig for .NET — fixtures, builders, and assertions for SQL, NoSQL, messaging, caching, storage, observability, security, and microservices.
dotnet add package Rig.TUnit --prerelease
dotnet add package Rig.TUnit.Databases.Sql.Postgresql --prerelease
[Test]
public async Task Repository_Persists(CancellationToken ct)
{
await using var db = new PostgresFixture();
await db.InitializeAsync();
await using var conn = new NpgsqlConnection(db.ConnectionString);
await conn.ExecuteAsync("INSERT INTO orders (id) VALUES (gen_random_uuid())");
var count = await conn.ExecuteScalarAsync<int>("SELECT COUNT(*) FROM orders");
await Assert.That(count).IsEqualTo(1);
}
What's inside
- Container fixtures — one-line Testcontainers setup for every major datastore and broker.
- Provider-specific assertions — fluent assertions tailored to each backend (tables, message ordering, blob existence, JWT claims, …).
- Unified builder API —
services.AddRigTUnit(rig => rig.Use<X>(…))wires fixtures into DI-first test setup. - Per-test isolation — every fixture derives an
IsolationKeyfrom the test execution context, guaranteeing zero cross-test state leakage even under full parallelism.
Provider families
| Family | Packages |
|---|---|
| SQL | SqlServer · MySql · Postgresql · Oracle · Sqlite |
| NoSQL | Redis · Mongo · Cosmos · Cassandra · Dynamo · ElasticSearch · KurrentDb |
| Messaging | ServiceBus · Kafka · RabbitMq · Nats · Sqs |
| Caching | Redis · Memory · Fusion · Hybrid |
| Storage | AzureBlob · FileSystem · MinIO · S3 |
| Observability | Logging · AppInsights · Metrics · Tracing · Seq |
| Security | Jwt · Policies · OAuth · Mtls |
| Microservices | EventSourcing · Outbox · Inbox · Saga · Snapshots · Contracts |
| Infrastructure | Http · Grpc · HealthChecks · Resilience · Mediator · Docker · WebAPI |
Documentation
- Full README + provider docs: https://github.com/FaysilAlshareef/Rig.TUnit
- Quick-start, builder API, messaging topology, isolation guarantees: see the repo
README.md. - Per-provider READMEs ship inside each leaf source folder.
License
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. 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. |
-
net10.0
- Bogus (>= 35.6.1)
- Microsoft.Extensions.Configuration (>= 10.0.0)
- Microsoft.Extensions.Configuration.Binder (>= 10.0.0)
- Microsoft.Extensions.DependencyInjection.Abstractions (>= 10.0.0)
- Microsoft.Extensions.Options (>= 10.0.0)
- Microsoft.Extensions.Options.DataAnnotations (>= 10.0.0)
- Rig.TUnit.Core (>= 0.0.0-alpha.0.14)
- TUnit.Core (>= 1.34.5)
NuGet packages (4)
Showing the top 4 NuGet packages that depend on Rig.TUnit.Databases:
| Package | Downloads |
|---|---|
|
Rig.TUnit.Databases.NoSql
NoSQL family base - INoSqlFixture, change-feed utilities, conflict-resolution helpers. Pull a leaf provider for a working fixture. |
|
|
Rig.TUnit.Databases.Sql
SQL family base - ISqlFixture, schema helpers, transaction-isolation utilities. Pull a leaf package (SqlServer, Postgresql, MySql, Oracle, Sqlite) for a working fixture. |
|
|
Rig.TUnit.Microservices.Outbox
TUnit fixture for the transactional outbox pattern - visibility-timeout helpers, dispatcher assertions, and dedup checks. |
|
|
Rig.TUnit.All
Meta-package containing every Rig.TUnit.* package. DISCOURAGED — prefer per-feature or per-stack meta-packages (Rig.TUnit, Rig.TUnit.Microservices). |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.1.0-beta.2 | 69 | 4/27/2026 |
| 0.0.0-alpha.0.14 | 73 | 4/26/2026 |