コード例 #1
0
        public void SetUp()
        {
            _matchFixtureService = MockRepository.GenerateMock <IMatchFixtureService>();
            _mapper     = MockRepository.GenerateMock <IMappingEngine>();
            _controller = new MatchFixtureController(_matchFixtureService, _mapper);

            // Mocking Context for the controller
            var request = MockRepository.GenerateMock <HttpRequestMessage>();

            _controller.Request = request;
            _controller.Request.Properties.Add(HttpPropertyKeys.HttpConfigurationKey, new HttpConfiguration());
        }
コード例 #2
0
 public void SetUp()
 {
     _matchFixtureService = MockRepository.GenerateMock <IMatchFixtureService>();
     _mapper     = MockRepository.GenerateMock <IMappingEngine>();
     _controller = new MatchFixtureController(_matchFixtureService, _mapper);
 }