Ejemplo n.º 1
0
        static void MigrateDatabase()
        {
            var cloner = new DbCloner("zero-k_ef", "zero-k_test",
                                      "Data Source=omega.licho.eu,100;Initial Catalog=zero-k_test;Persist Security Info=True;User ID=zero-k;Password=zkdevpass1;MultipleActiveResultSets=true");

            cloner.CloneAllTables();
        }
Ejemplo n.º 2
0
        static void MigrateDatabase()
        {
            GlobalConst.Mode = ModeType.Test;
            var cloner = new DbCloner("zero-k", "zero-k_test", GlobalConst.ZkDataContextConnectionString);

            cloner.LogEvent += s => { Console.WriteLine(s); };
            cloner.CloneAllTables();
        }
 public ActionResult ResetDb() {
     if (GlobalConst.Mode == ModeType.Test)
     {
         var cloner = new DbCloner("zero-k", "zero-k_test", GlobalConst.ZkDataContextConnectionString);
         cloner.LogEvent += s => { Response.Write(s); Response.Flush(); };
         cloner.CloneAllTables();
         Response.Write("DONE! Database copied");
         Response.Flush();
         return Content("");
     } else return Content("Not allowed!");
 }
Ejemplo n.º 4
0
 public ActionResult ResetDb()
 {
     if (GlobalConst.Mode == ModeType.Test)
     {
         var cloner = new DbCloner("zero-k", "zero-k_test", GlobalConst.ZkDataContextConnectionString);
         cloner.LogEvent += s =>
         {
             Response.Write(s);
             Response.Flush();
         };
         cloner.CloneAllTables();
         Response.Write("DONE! Database copied");
         Response.Flush();
         return(Content(""));
     }
     else
     {
         return(Content("Not allowed!"));
     }
 }
Ejemplo n.º 5
0
 static void MigrateDatabase()
 {
     GlobalConst.Mode = ModeType.Test;
     var cloner = new DbCloner("zero-k", "zero-k_test", GlobalConst.ZkDataContextConnectionString);
     cloner.LogEvent += s => { Console.WriteLine(s); };
     cloner.CloneAllTables();
 }
Ejemplo n.º 6
0
 static void MigrateDatabase()
 {
     var cloner = new DbCloner("zero-k_ef", "zero-k_test",
         "Data Source=omega.licho.eu,100;Initial Catalog=zero-k_test;Persist Security Info=True;User ID=zero-k;Password=zkdevpass1;MultipleActiveResultSets=true");
     cloner.CloneAllTables();
 }