|
|
@ -81,9 +81,13 @@ public class AppBootstrap(IConfiguration configuration)
|
|
|
|
switch (Environment.GetEnvironmentVariable("TYPE"))
|
|
|
|
switch (Environment.GetEnvironmentVariable("TYPE"))
|
|
|
|
{
|
|
|
|
{
|
|
|
|
case "BDD":
|
|
|
|
case "BDD":
|
|
|
|
|
|
|
|
Console.WriteLine("====== RUNNING USING THE MYSQL SERVER Here ensure created ======");
|
|
|
|
services.AddSingleton<IDataManager>(provider =>
|
|
|
|
services.AddSingleton<IDataManager>(provider =>
|
|
|
|
{
|
|
|
|
{
|
|
|
|
provider.GetRequiredService<TrainingStubbedContext>().Database.EnsureCreated();
|
|
|
|
provider.GetRequiredService<TrainingStubbedContext>().Database.EnsureCreated();
|
|
|
|
|
|
|
|
Console.WriteLine(provider.GetRequiredService<TrainingStubbedContext>().Database.EnsureCreated());
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Console.WriteLine(provider.GetRequiredService<TrainingStubbedContext>().Database.GetPendingMigrations());
|
|
|
|
return new DbDataManager(provider.GetRequiredService<HeartTrackContext>());
|
|
|
|
return new DbDataManager(provider.GetRequiredService<HeartTrackContext>());
|
|
|
|
});
|
|
|
|
});
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|