public void WhenIRender(string route)
        {
            umbracoViewsUnderTest.LoadAtRoute(route);
            umbracoViewsUnderTest.SetupView();

            if (usingTypedModels)
            {
                viewsUnderTest.RenderAsHtml(umbracoViewsUnderTest.Content);
            }
            else
            {
                viewsUnderTest.RenderAsHtml(new RenderModel <IPublishedContent>(umbracoViewsUnderTest.Content, CultureInfo.CurrentCulture));
            }

            Console.WriteLine(viewsUnderTest.Output);
        }
        public void WhenIPressAdd()
        {
            viewsUnderTest.AddPartial <_Views_Addition_Index_cshtml>("Index");

            umbracoViewsUnderTest.LoadAtRoute("/learn/masterclasses");
            umbracoViewsUnderTest.SetupView();

            var routeData = new RouteData();

            routeData.DataTokens.Add("ParentActionViewContext", viewsUnderTest.Instance.ViewContext);

            var controller = new AdditionController();

            controller.ControllerContext = new ControllerContext(viewsUnderTest.HttpContextBase, routeData, controller);
            controller.Add(model);

            controllersUnderTest.Add("Addition", () => controller);

            UmbracoRouteBindings.EnsureRoutes();
            ControllersUnderTestSteps.EnsureControllerFactory(controllersUnderTest);
            viewsUnderTest.RenderAsHtml(new RenderModel <IPublishedContent>(umbracoViewsUnderTest.Content, CultureInfo.CurrentCulture));
        }
 public void WhenIUseTheRenderAsHtmlExtensionWithTheModel()
 {
     viewsUnderTest.RenderAsHtml(model);
 }