protected void Application_Start() { // detect routes to register RouteRegistration.RegisterRoutes(RouteTable.Routes); // default MVC application start tasks AreaRegistration.RegisterAllAreas(); RegisterGlobalFilters(GlobalFilters.Filters); RegisterRoutes(RouteTable.Routes); ViewEngines.Engines.Clear(); ViewEngines.Engines.Add(new RazorViewEngine()); // setup dependency injection SetUpDependencyInjection(); // set up fluent validation SetUpFluentValidation(); // configure automapper AutoMapperRegistration.RegisterProfiles(); // seed the database SeedData(); }
public static void RegisterAllRoutes(TestContext testContext) { // register routes once when the test suite begins RouteTable.Routes.Clear(); RouteRegistration.RegisterRoutes(RouteTable.Routes); AreaRegistration.RegisterAllAreas(); MvcApplication.RegisterRoutes(RouteTable.Routes); AutoMapperRegistration.RegisterProfiles(); }
public static RouteCollection GetRoutes() { var routes = new RouteCollection(); RouteRegistration.RegisterRoutes(routes); UCosmic.Www.Mvc.MvcApplication.RegisterRoutes(routes); RegisterAreaRoutes(routes); return(routes); }