QuickPersistr.EntityFrameworkCore 0.0.2

dotnet add package QuickPersistr.EntityFrameworkCore --version 0.0.2
                    
NuGet\Install-Package QuickPersistr.EntityFrameworkCore -Version 0.0.2
                    
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="QuickPersistr.EntityFrameworkCore" Version="0.0.2" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="QuickPersistr.EntityFrameworkCore" Version="0.0.2" />
                    
Directory.Packages.props
<PackageReference Include="QuickPersistr.EntityFrameworkCore" />
                    
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 QuickPersistr.EntityFrameworkCore --version 0.0.2
                    
#r "nuget: QuickPersistr.EntityFrameworkCore, 0.0.2"
                    
#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 QuickPersistr.EntityFrameworkCore@0.0.2
                    
#: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=QuickPersistr.EntityFrameworkCore&version=0.0.2
                    
Install as a Cake Addin
#tool nuget:?package=QuickPersistr.EntityFrameworkCore&version=0.0.2
                    
Install as a Cake Tool

QuickPersistr.EntityFrameworkCore

The provider-neutral Entity Framework Core adapter for QuickPersistr.

Use this package when your test environment already creates and owns the database. For a ready-made isolated database, use the SQLite or PostgreSQL provider package instead.

dotnet add package QuickPersistr.EntityFrameworkCore --version 0.0.1

Usage

Configure your EF provider normally and pass a context factory:

using Microsoft.EntityFrameworkCore;
using QuickPersistr;
using QuickPersistr.EntityFrameworkCore;

var options = new DbContextOptionsBuilder<LibraryDbContext>()
    .UseYourProvider(testDatabaseConnectionString)
    .Options;

Persistr.Named("Books")
    .Scope(() => new EfPersistenceScope<LibraryDbContext>(
        () => new LibraryDbContext(options)))
    .Entities(new BookPersistence())
    .Run();

UseYourProvider represents the configuration extension supplied by the provider you choose.

Database lifecycle

The scope:

  • creates and disposes every DbContext;
  • calls Database.EnsureCreated() by default;
  • creates fresh contexts for StartNewSession();
  • creates independent contexts for optimistic-concurrency scenarios.

The context factory must always connect to the same isolated test database for the lifetime of the scope. The scope does not own external connections, containers, servers, or database cleanup. Pass ensureCreated: false when schema creation is handled by migrations or test infrastructure.

This package supports EF Core 8.x and targets .NET 8. QuickPersistr is an early preview. APIs may change before version 1.0.

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 (2)

Showing the top 2 NuGet packages that depend on QuickPersistr.EntityFrameworkCore:

Package Downloads
QuickPersistr.EntityFrameworkCore.Sqlite

Isolated in-memory SQLite persistence scope for QuickPersistr and Entity Framework Core.

QuickPersistr.EntityFrameworkCore.PostgreSql

Isolated temporary PostgreSQL database scope for QuickPersistr and Entity Framework Core.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.0.2 129 8/8/2026
0.0.1 131 8/7/2026