private JewelryItemController CreateJewelryItemControllerWithCustomWishListPersistence( IWishListPersistence wishListPersistence) { var fileSystem = FakeFileSystem.MediaFileSystemForItemNumber("0101-15421"); var settingManager = new FakeSettingManager(); var jewelryRepository = new FakeJewelRepository(settingManager); var webHelpers = GetWebHelpers(); var mediaSetBuilder = GetMediaSetBuilder(); var bestOffer = MockRepository.GenerateStub<IBestOffer>(); var fakeTestimonailRepository = new FakeTestimonialRepository(mapper); var fakeMailer = MockRepository.GenerateStub<IUserMailer>(); var pathbarGenerator = MockRepository.GenerateStub<IPathBarGenerator>(); var controller = new JewelryItemController(jewelryRepository, mediaSetBuilder, webHelpers, fileSystem, bestOffer, wishListPersistence, fakeTestimonailRepository, fakeMailer, pathbarGenerator, mapper); return controller; }
private JewelryItemController CreateDefaultJewelryItemControllerSetup() { var fileSystem = FakeFileSystem.MediaFileSystemForItemNumber(Tests.FAKE_JEWEL_ITEMNUMBER); var settingManager = new FakeSettingManager(); var jewelryRepository = new FakeJewelRepository(settingManager); var webHelpers = GetWebHelpers(); var mediaSetBuilder = GetMediaSetBuilder(); var fakeTestimonailRepository = new FakeTestimonialRepository(mapper); var bestOffer = MockRepository.GenerateStub<IBestOffer>(); var wishListPersistence = MockRepository.GenerateStub<IWishListPersistence>(); var fakeMailer = MockRepository.GenerateStub<IUserMailer>(); var pathbarGenerator = MockRepository.GenerateStub<IPathBarGenerator>(); var controller = new JewelryItemController(jewelryRepository, mediaSetBuilder, webHelpers, fileSystem, bestOffer, wishListPersistence, fakeTestimonailRepository, fakeMailer, pathbarGenerator, mapper); return controller; }