DBMocker to validate and mock SQL Queries NuGet Package

This .NET library simplifies data mocking for UnitTests, to avoid a connection to a relational database.
DbMocker use the standard Microsoft .NET DbConnection object.

So, you can mock any toolkit,
including EntityFramework, Dapper or ADO.NET; And for all database servers (SQL Server, Oracle, SQLite).

```csharp
var conn = new MockDbConnection();
conn.Mocks
.When(cmd => cmd.CommandText.Contains("SELECT COUNT(*) FROM EMP"))
.ReturnsScalar(14);
```.




Got any DBMocker to validate and mock SQL Queries Question?





Info

Version: 2.0.1-preview
Author(s): Denis Voituron
Last Update: Sunday, February 4, 2024
.NET Fiddle: Create the first Fiddle
Project Url: https://github.com/Apps72/DbMocker
NuGet Url: https://www.nuget.org/packages/DbMocker


Install
Install-Package DbMocker
dotnet add package DbMocker
paket add DbMocker
DbMocker Download (Unzip the "nupkg" after downloading)



Tags



STATS

must-have-score

3.8

avg-downloads-per-day

102

days-since-last-release

291