EfCore.TestSupport 1.8.0

Useful tools when unit testing applications that use Entity Framework Core. See readme file on github.

Install-Package EfCore.TestSupport -Version 1.8.0
dotnet add package EfCore.TestSupport --version 1.8.0
paket add EfCore.TestSupport --version 1.8.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

EfCore.TestSupport

This git repo contains the source of the EfCore.TestSupport, and various tests to check the EfCore.TestSupport NuGet package. See Release Notes for information on changes. This project is open-source (MIT licence).

Documentation

The NuGet package EfCore.TestSupport is a netstandard2.0 library containing methods to help you unit test applications that use
Entity Framework Core for database access. This readme defines the various groups, with links to the documentation in the
EfCore.TestSupport wiki.

NOTE: The techniques are explained in much more details in chapter 15 of the book Entity Framework in Action.

The various groups of tools are:

  1. Helpers to create an in-memory Sqlite database for unit testing.
    See Sqlite in memory test database.
  2. Helpers to create an InMemory database for unit testing.
    See EF InMemory test database.
  3. Helpers to create connection strings with a unique database name.
    See Creating connection strings.
  4. Helpers for creating unique SQL Server databases for unit testing.
    See Create SQL Server databases.
  5. Helpers for creating an empty database, and deleting SQL unit test databases.
    See Quickly create empty databases.
  6. Various tools for getting test data, or file paths to test data.
    See Test Data tools.
  7. A tool for applying a SQL script file to a EF Core database.
    See Run SQL Script.
  8. Tools for capturing EF Core logging.
    See Capture EF Core logging.
  9. Tool to compare EF Core's view of the database with an actual database.
    See EfSchemaCompare.

EfCore.TestSupport

This git repo contains the source of the EfCore.TestSupport, and various tests to check the EfCore.TestSupport NuGet package. See Release Notes for information on changes. This project is open-source (MIT licence).

Documentation

The NuGet package EfCore.TestSupport is a netstandard2.0 library containing methods to help you unit test applications that use
Entity Framework Core for database access. This readme defines the various groups, with links to the documentation in the
EfCore.TestSupport wiki.

NOTE: The techniques are explained in much more details in chapter 15 of the book Entity Framework in Action.

The various groups of tools are:

  1. Helpers to create an in-memory Sqlite database for unit testing.
    See Sqlite in memory test database.
  2. Helpers to create an InMemory database for unit testing.
    See EF InMemory test database.
  3. Helpers to create connection strings with a unique database name.
    See Creating connection strings.
  4. Helpers for creating unique SQL Server databases for unit testing.
    See Create SQL Server databases.
  5. Helpers for creating an empty database, and deleting SQL unit test databases.
    See Quickly create empty databases.
  6. Various tools for getting test data, or file paths to test data.
    See Test Data tools.
  7. A tool for applying a SQL script file to a EF Core database.
    See Run SQL Script.
  8. Tools for capturing EF Core logging.
    See Capture EF Core logging.
  9. Tool to compare EF Core's view of the database with an actual database.
    See EfSchemaCompare.

Release Notes

- Improvement: CompareEfSql now recoginises unique indexes provided by constraints (rather than via the normal SQL Index statement)
     - Improvement: CompareEfSqlConfig.TablesToIgnoreCommaDelimited should trim tables names are ignore null entries
     - Feature: Added WipeCreateDatabase extension method - useful for creating empty database prior to using SQL to add tables etc.

Version History

Version Downloads Last updated
1.8.0 0 3/25/2019
1.7.0 166 3/19/2019
1.6.1 1,573 1/28/2019
1.6.0 44 1/28/2019
1.5.2 1,231 1/4/2019
1.5.1 4,746 10/24/2018
1.5.0 1,301 10/2/2018
1.4.0 6,438 6/7/2018
1.3.1 1,626 4/1/2018
1.3.0 1,043 3/1/2018
1.2.0 456 1/22/2018
1.1.5 316 12/27/2017
1.1.4 214 12/27/2017
1.1.3 335 12/1/2017
1.1.2 202 11/21/2017
1.1.1 194 11/17/2017
1.1.0 207 11/16/2017
1.0.2 197 10/13/2017
1.0.1 184 9/30/2017
1.0.0 226 9/29/2017