예제 #1
0
        public void RemoveItem_should_remove_item_from_basket()
        {
            _baskets.Add(new Basket(_testCustomerId,
                                    new List <Item>
            {
                new Item("Item1", 2)
            }));

            _sut.RemoveItem(_testCustomerId, "Item1");

            _baskets.First().Items.Count.Should().Be(0);
        }
예제 #2
0
 public Basket RemoveItem(string customerId, string itemId)
 {
     _basketStore.RemoveItem(customerId, itemId);
     return(GetBasketByCustomerId(customerId));
 }