Пример #1
0
        public UpdateAgedBrieTests()
        {
            _increaseQuality = Substitute.For <IIncreaseQuality>();
            _decreaseSellIn  = Substitute.For <IDecreaseSellIn>();

            _sut = new UpdateAgedBrie(_increaseQuality, _decreaseSellIn);
        }
Пример #2
0
        private void RunProgram(List <Item> items)
        {
            var updateAgedBrie       = new UpdateAgedBrie(new IncreaseQuality(), new DecreaseSellIn());
            var updateBackStageItems = new UpdateBackStageItems(new IncreaseQuality(), new DecreaseSellIn());
            var updateOrdinaryItems  = new UpdateOrdinaryItem(new DecreaseQuality(), new DecreaseSellIn());
            var updateConjuredItems  = new UpdateConjuredItems(new DecreaseQuality(), new DecreaseSellIn());

            var updateInventory = new UpdateInventory(updateBackStageItems, updateAgedBrie, updateConjuredItems,
                                                      updateOrdinaryItems);

            var app = new Program(items, updateInventory);

            app.UpdateQuality();
        }