private void InitializeWarehouse(IList <Item> items)
        {
            _warehouse = new List <WarehouseItem>();

            if (items == null || !items.Any())
            {
                return;
            }

            foreach (var item in items)
            {
                _warehouse.Add(new WarehouseItem()
                {
                    Item     = item,
                    Category = WarehouseItemCategories.GetCategory(item.Name)
                });
            }
        }
示例#2
0
 public void GetWarehouseItemCategory_PASS(string itemName, string expectedCategory)
 {
     Assert.AreEqual(expectedCategory, WarehouseItemCategories.GetCategory(itemName));
 }