public BookStoreMigrationsDbContext CreateDbContext(string[] args) { BookStoreEfCoreEntityExtensionMappings.Configure(); var configuration = BuildConfiguration(); var builder = new DbContextOptionsBuilder <BookStoreMigrationsDbContext>() .UseSqlServer(configuration.GetConnectionString("Default")); return(new BookStoreMigrationsDbContext(builder.Options)); }
public override void PreConfigureServices(ServiceConfigurationContext context) { BookStoreEfCoreEntityExtensionMappings.Configure(); }