Exemplo n.º 1
0
        protected void Application_Start()
        {
            FeliceCore.Initialize();

            Database.Initialize();
            Database.MigrateToLastVersion();

            AreaRegistration.RegisterAllAreas();

            //// TODO: dry
            DependencyResolver.SetResolver(new StructureMapDependencyResolver());
            FilterProviders.Providers.Add(new StructureMapFilterAttributeFilterProvider());

            //// TODO: dry
            GlobalFilters.Filters.Add(new HandleErrorAttribute());
            GlobalFilters.Filters.Add(new UnitOfWorkFilter());

            //// TODO: dry
            ViewEngines.Engines.Clear();
            ViewEngines.Engines.Add(new RazorViewEngine());

            WebApiConfig.Register(GlobalConfiguration.Configuration);
            FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
            RouteConfig.RegisterRoutes(RouteTable.Routes);
        }
Exemplo n.º 2
0
        protected void Application_Start()
        {
            //// Inicializa felice framework
            FeliceCore.Initialize();

            Database.AddMigrations(typeof(MvcApplication).Assembly);
            Database.AddMappings(typeof(TratamentoMap).Assembly);
            Database.Initialize();

            Database.MigrateToLastVersion();

            DependencyResolver.SetResolver(new StructureMapDependencyResolver());
            FilterProviders.Providers.Add(new StructureMapFilterAttributeFilterProvider());

            GlobalFilters.Filters.Add(new HandleErrorAttribute());
            GlobalFilters.Filters.Add(new UnitOfWorkFilter());

            ViewEngines.Engines.Clear();
            ViewEngines.Engines.Add(new RazorViewEngine());

            AreaRegistration.RegisterAllAreas();

            WebApiConfig.Register(GlobalConfiguration.Configuration);
            FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
            RouteConfig.RegisterRoutes(RouteTable.Routes);
            BundleConfig.RegisterBundles(BundleTable.Bundles);
        }
Exemplo n.º 3
0
        protected void Application_Start()
        {
            FeliceCore.Initialize()
            .InitializeDatabase()
            .InitializeMvc();

            Database.MigrateToLastVersion();

            RouteConfig.RegisterRoutes(RouteTable.Routes);
        }
Exemplo n.º 4
0
        static AutomatedTest()
        {
            FeliceCore.Initialize();

            Log.Framework.DebugFormat("Building test scenario executing your IScenarioBuilder");

            //var testScenario = Dependency.Resolve<IScenarioBuilder>();

            //if (testScenario != null)
            //{
            //    testScenario.Define();
            //}
        }
Exemplo n.º 5
0
 public static void Main(string[] args)
 {
     FeliceCore.Initialize();
     new FeliceTasks().Execute(args);
 }