示例#1
0
        public PwaTestMigrationsDbContext CreateDbContext(string[] args)
        {
            PwaTestEfCoreEntityExtensionMappings.Configure();

            var configuration = BuildConfiguration();

            var builder = new DbContextOptionsBuilder <PwaTestMigrationsDbContext>()
                          .UseSqlServer(configuration.GetConnectionString("Default"));

            return(new PwaTestMigrationsDbContext(builder.Options));
        }
示例#2
0
 public override void PreConfigureServices(ServiceConfigurationContext context)
 {
     PwaTestEfCoreEntityExtensionMappings.Configure();
 }