public void InitializeDatabase() { var isCreated = (context.GetService <IDatabaseCreator>() as RelationalDatabaseCreator).Exists(); if (!isCreated) { this.context.Database.Migrate(); InsertSuppliers(); InsertParts(); InsertCars(); InserCustomers(); InsertSales(); } }