public static void Initialize(TestContext testContext)
        {
            var context = new EventContext();
            context.Database.Delete();

            var configuration = new TestMigrationConfiguration();
            var migrator = new DbMigrator(configuration);
            migrator.Update();
        }
Beispiel #2
0
        public static void ClassCleanup()
        {
            // Since users are not cleaned up by transactions (why is this?), we need to clear the state
            // after these tests have been run.
            using (var context = new EventContext())
            {
                context.Database.Delete();

                var configuration = new TestMigrationConfiguration();
                var migrator      = new DbMigrator(configuration);
                migrator.Update();
            }
        }
        public static void ClassCleanup()
        {
            // Since users are not cleaned up by transactions (why is this?), we need to clear the state
            // after these tests have been run.
            using (var context = new EventContext())
            {
                context.Database.Delete();

                var configuration = new TestMigrationConfiguration();
                var migrator = new DbMigrator(configuration);
                migrator.Update();
            }
        }