Exemple #1
0
        private void Init()
        {
            _dbContext = new TrackytDataContext(ConfigurationManager.ConnectionStrings["testdb"].ConnectionString);
            RepositoriesInitializer.InitDB(_dbContext);

            _dbContext.Database.Connection.Open();
            _transaction = new TransactionScope();


            AddTestUser();
            AddTestProject();
        }
Exemple #2
0
        protected void Application_Start()
        {
            RepositoriesInitializer.InitDB(new TrackytDataContext());

            // Routing
            AreaRegistration.RegisterAllAreas();
            RegisterRoutes(RouteTable.Routes);

            // Dependency injection
            ControllerBuilder.Current.SetControllerFactory(new TrackyControllerFactory());

            // Auto-mapper
            TrackyMapping.SetupMapping();

            // RouteDebugger
            //RouteDebug.RouteDebugger.RewriteRoutesForTesting(RouteTable.Routes);
        }