public static void ClassInit(TestContext context1)
        {
            Container.Install(new BussinessLayerInstaller());
            MappingInit.ConfigureMapping();
            _albumService     = Container.Resolve <IAlbumService>();
            _interpretService = Container.Resolve <IInterpretService>();

            DeleteTables();
        }
Пример #2
0
        public static void ClassInit(TestContext context1)
        {
            Container.Install(new BussinessLayerInstaller());
            MappingInit.ConfigureMapping();
            _playlistService    = Container.Resolve <IPlaylistService>();
            _userService        = Container.Resolve <IUserService>();
            _userAccountService = Container.Resolve <BrockAllen.MembershipReboot.UserAccountService <UserAccount> >();

            DeleteTables();
        }
        protected void Application_Start()
        {
            AreaRegistration.RegisterAllAreas();
            GlobalConfiguration.Configure(WebApiConfig.Register);
            FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
            RouteConfig.RegisterRoutes(RouteTable.Routes);
            BundleConfig.RegisterBundles(BundleTable.Bundles);

            BootstrapContainer();
            MappingInit.ConfigureMapping();
        }
        private void BootstrapContainer()
        {
            container = new WindsorContainer();

            // configure DI
            container.Install(new BussinessLayerInstaller());
            container.Install(new MvcInstaller());

            // configure mapping within BL
            MappingInit.ConfigureMapping();

            // initialize default user accounts (admin, ...)
            UserAccountInit.InitializeUserAccounts(container);

            // set controller factory
            var controllerFactory = new WindsorControllerFactory(container.Kernel);

            ControllerBuilder.Current.SetControllerFactory(controllerFactory);
        }
Пример #5
0
 private static void InitializeWindsorContainerAndMapper()
 {
     Container.Install(new BussinessLayerInstaller());
     MappingInit.ConfigureMapping();
 }