Example #1
0
 public void TestSetup()
 {
     _mocks       = new MockRepository();
     _viewData    = new ViewDataDictionary();
     _mockRequest = _mocks.DynamicMock <HttpRequestBase>();
     _html        = WebTestUtility.BuildHtmlHelper(_mocks, _viewData, _mockRequest);
     _mocks.ReplayAll();
 }
        public void TestSetup()
        {
            _viewData = new ViewDataDictionary();
            _mocks    = new MockRepository();
            _mockHttpContextProvider = _mocks.Stub <IHttpContextProvider>();
            _mockHttpContextProvider.Expect(hcp => hcp.Request).Return(_mocks.Stub <HttpRequestBase>()).Repeat.Twice();
            _mockSettings = _mocks.Stub <IIncludeHandlingSettings>();

            _html = WebTestUtility.BuildHtmlHelper(_mocks, _viewData, null);
            _mocks.ReplayAll();
            var resolver = new QnDDepResolver(_mockHttpContextProvider, _mockSettings, new Controller[] { });

            DependencyResolver.InitializeWith(resolver);
        }