TestHelpers TestHelpers Class

Syntax

Declaration

public class TestHelpersPublic Class TestHelpers

Inheritance Hierarchy

  • System.Object
    System.Object
  • TestHelpers
    TestHelpers

Inherited Members

ToString(),
ToString(),
Equals(Object),
Equals(Object),
Equals(Object, Object),
Equals(Object, Object),
ReferenceEquals(Object, Object),
ReferenceEquals(Object, Object),
GetHashCode(),
GetHashCode(),
GetType(),
GetType(),
MemberwiseClone()
MemberwiseClone()

Constructors summary

Properties summary

Methods summary

Constructors

  • TestHelpers()
    TestHelpers()
    protected TestHelpers()Protected Sub New

Properties

  • Instance
    Instance
    public static TestHelpers Instance { get; }Public Shared ReadOnly Property Instance As TestHelpers

    Property Value

Methods

  • AddProviderServices(IServiceCollection)
    AddProviderServices(IServiceCollection)
    public virtual IServiceCollection AddProviderServices(IServiceCollection services)Public Overridable Function AddProviderServices(services As IServiceCollection) As IServiceCollection

    Parameters

    • services
      IServiceCollection
      IServiceCollection

    Returns

    • IServiceCollection
      IServiceCollection
  • AssertResults<T>(IList<T>, IList<T>, Boolean, Action<IList<T>, IList<T>>)
    AssertResults(Of T)(IList(Of T), IList(Of T), Boolean, Action(Of IList(Of T), IList(Of T)))
    public static int AssertResults<T>(IList<T> expected, IList<T> actual, bool assertOrder, Action<IList<T>, IList<T>> asserter = null)Public Shared Function AssertResults(Of T)(expected As IList(Of T), actual As IList(Of T), assertOrder As Boolean, asserter As Action(Of IList(Of T), IList(Of T)) = Nothing) As Integer

    Parameters

    • expected
      System.Collections.Generic.IList<T><T>
      System.Collections.Generic.IList<T>(Of T)
    • actual
      System.Collections.Generic.IList<T><T>
      System.Collections.Generic.IList<T>(Of T)
    • assertOrder
      System.Boolean
      System.Boolean
    • asserter
      System.Action<T1, T2><System.Collections.Generic.IList<T><T>, System.Collections.Generic.IList<T><T>>
      System.Action<T1, T2>(Of System.Collections.Generic.IList<T>(Of T), System.Collections.Generic.IList<T>(Of T))

    Returns

    • System.Int32
      System.Int32
  • BuildModelFor<TEntity>()
    BuildModelFor(Of TEntity)()
    public IMutableModel BuildModelFor<TEntity>()where TEntity : classPublic Function BuildModelFor(Of TEntity As Class) As IMutableModel

    Returns

  • CreateContext()
    CreateContext()
    public DbContext CreateContext()Public Function CreateContext As DbContext

    Returns

  • CreateContext(IServiceCollection)
    CreateContext(IServiceCollection)
    public DbContext CreateContext(IServiceCollection customServices)Public Function CreateContext(customServices As IServiceCollection) As DbContext

    Parameters

    • customServices
      IServiceCollection
      IServiceCollection

    Returns

  • CreateContext(IServiceCollection, DbContextOptions)
    CreateContext(IServiceCollection, DbContextOptions)
    public DbContext CreateContext(IServiceCollection customServices, DbContextOptions options)Public Function CreateContext(customServices As IServiceCollection, options As DbContextOptions) As DbContext

    Parameters

    Returns

  • CreateContext(IServiceCollection, IModel)
    CreateContext(IServiceCollection, IModel)
    public DbContext CreateContext(IServiceCollection customServices, IModel model)Public Function CreateContext(customServices As IServiceCollection, model As IModel) As DbContext

    Parameters

    • customServices
      IServiceCollection
      IServiceCollection
    • model

    Returns

  • CreateContext(DbContextOptions)
    CreateContext(DbContextOptions)
    public DbContext CreateContext(DbContextOptions options)Public Function CreateContext(options As DbContextOptions) As DbContext

    Parameters

    Returns

  • CreateContext(IModel)
    CreateContext(IModel)
    public DbContext CreateContext(IModel model)Public Function CreateContext(model As IModel) As DbContext

    Parameters

    Returns

  • CreateContext(IServiceProvider)
    CreateContext(IServiceProvider)
    public DbContext CreateContext(IServiceProvider serviceProvider)Public Function CreateContext(serviceProvider As IServiceProvider) As DbContext

    Parameters

    • serviceProvider
      System.IServiceProvider
      System.IServiceProvider

    Returns

  • CreateContext(IServiceProvider, DbContextOptions)
    CreateContext(IServiceProvider, DbContextOptions)
    public DbContext CreateContext(IServiceProvider serviceProvider, DbContextOptions options)Public Function CreateContext(serviceProvider As IServiceProvider, options As DbContextOptions) As DbContext

    Parameters

    Returns

  • CreateContext(IServiceProvider, IModel)
    CreateContext(IServiceProvider, IModel)
    public DbContext CreateContext(IServiceProvider serviceProvider, IModel model)Public Function CreateContext(serviceProvider As IServiceProvider, model As IModel) As DbContext

    Parameters

    • serviceProvider
      System.IServiceProvider
      System.IServiceProvider
    • model

    Returns

  • CreateContextServices()
    CreateContextServices()
    public IServiceProvider CreateContextServices()Public Function CreateContextServices As IServiceProvider

    Returns

    • System.IServiceProvider
      System.IServiceProvider
  • CreateContextServices(IServiceCollection)
    CreateContextServices(IServiceCollection)
    public IServiceProvider CreateContextServices(IServiceCollection customServices)Public Function CreateContextServices(customServices As IServiceCollection) As IServiceProvider

    Parameters

    • customServices
      IServiceCollection
      IServiceCollection

    Returns

    • System.IServiceProvider
      System.IServiceProvider
  • CreateContextServices(IServiceCollection, DbContextOptions)
    CreateContextServices(IServiceCollection, DbContextOptions)
    public IServiceProvider CreateContextServices(IServiceCollection customServices, DbContextOptions options)Public Function CreateContextServices(customServices As IServiceCollection, options As DbContextOptions) As IServiceProvider

    Parameters

    Returns

    • System.IServiceProvider
      System.IServiceProvider
  • CreateContextServices(IServiceCollection, IModel)
    CreateContextServices(IServiceCollection, IModel)
    public IServiceProvider CreateContextServices(IServiceCollection customServices, IModel model)Public Function CreateContextServices(customServices As IServiceCollection, model As IModel) As IServiceProvider

    Parameters

    • customServices
      IServiceCollection
      IServiceCollection
    • model

    Returns

    • System.IServiceProvider
      System.IServiceProvider
  • CreateContextServices(DbContextOptions)
    CreateContextServices(DbContextOptions)
    public IServiceProvider CreateContextServices(DbContextOptions options)Public Function CreateContextServices(options As DbContextOptions) As IServiceProvider

    Parameters

    Returns

    • System.IServiceProvider
      System.IServiceProvider
  • CreateContextServices(IModel)
    CreateContextServices(IModel)
    public IServiceProvider CreateContextServices(IModel model)Public Function CreateContextServices(model As IModel) As IServiceProvider

    Parameters

    Returns

    • System.IServiceProvider
      System.IServiceProvider
  • CreateContextServices(IServiceProvider)
    CreateContextServices(IServiceProvider)
    public IServiceProvider CreateContextServices(IServiceProvider serviceProvider)Public Function CreateContextServices(serviceProvider As IServiceProvider) As IServiceProvider

    Parameters

    • serviceProvider
      System.IServiceProvider
      System.IServiceProvider

    Returns

    • System.IServiceProvider
      System.IServiceProvider
  • CreateContextServices(IServiceProvider, DbContextOptions)
    CreateContextServices(IServiceProvider, DbContextOptions)
    public IServiceProvider CreateContextServices(IServiceProvider serviceProvider, DbContextOptions options)Public Function CreateContextServices(serviceProvider As IServiceProvider, options As DbContextOptions) As IServiceProvider

    Parameters

    Returns

    • System.IServiceProvider
      System.IServiceProvider
  • CreateContextServices(IServiceProvider, IModel)
    CreateContextServices(IServiceProvider, IModel)
    public IServiceProvider CreateContextServices(IServiceProvider serviceProvider, IModel model)Public Function CreateContextServices(serviceProvider As IServiceProvider, model As IModel) As IServiceProvider

    Parameters

    • serviceProvider
      System.IServiceProvider
      System.IServiceProvider
    • model

    Returns

    • System.IServiceProvider
      System.IServiceProvider
  • CreateConventionBuilder()
    CreateConventionBuilder()
    public ModelBuilder CreateConventionBuilder()Public Function CreateConventionBuilder As ModelBuilder

    Returns

  • CreateInternalEntry<TEntity>(IModel, EntityState, TEntity)
    CreateInternalEntry(Of TEntity)(IModel, EntityState, TEntity)
    public InternalEntityEntry CreateInternalEntry<TEntity>(IModel model, EntityState entityState = EntityState.Detached, TEntity entity = null)where TEntity : class, new ()Public Function CreateInternalEntry(Of TEntity As {Class, New})(model As IModel, entityState As EntityState = EntityState.Detached, entity As TEntity = Nothing) As InternalEntityEntry

    Parameters

    Returns

  • CreateOptions(IModel, IServiceProvider)
    CreateOptions(IModel, IServiceProvider)
    public DbContextOptions CreateOptions(IModel model, IServiceProvider serviceProvider = null)Public Function CreateOptions(model As IModel, serviceProvider As IServiceProvider = Nothing) As DbContextOptions

    Parameters

    • model
    • serviceProvider
      System.IServiceProvider
      System.IServiceProvider

    Returns

  • CreateOptions(IServiceProvider)
    CreateOptions(IServiceProvider)
    public DbContextOptions CreateOptions(IServiceProvider serviceProvider = null)Public Function CreateOptions(serviceProvider As IServiceProvider = Nothing) As DbContextOptions

    Parameters

    • serviceProvider
      System.IServiceProvider
      System.IServiceProvider

    Returns

  • CreateServiceProvider(IServiceCollection)
    CreateServiceProvider(IServiceCollection)
    public IServiceProvider CreateServiceProvider(IServiceCollection customServices = null)Public Function CreateServiceProvider(customServices As IServiceCollection = Nothing) As IServiceProvider

    Parameters

    • customServices
      IServiceCollection
      IServiceCollection

    Returns

    • System.IServiceProvider
      System.IServiceProvider
  • UseProviderOptions(DbContextOptionsBuilder)
    UseProviderOptions(DbContextOptionsBuilder)
    protected virtual void UseProviderOptions(DbContextOptionsBuilder optionsBuilder)Protected Overridable Sub UseProviderOptions(optionsBuilder As DbContextOptionsBuilder)

    Parameters

Details

Assembly

Microsoft.EntityFrameworkCore.Specification.Tests.dll