예제 #1
0
        public void WeaponCollection_GetAllWeaponsOfType_ListOfWeapons(WeaponType type, int expectedValue)
        {
            // TODO: call WeaponCollection.GetAllWeaponsOfType(type) and confirm that the weapons list returns Count matches the expected value using asserts.
            List <Weapon> weaponList = weaponCollection.GetAllWeaponOfType(type);

            foreach (var weapon in weaponList)
            {
                Assert.AreEqual(weapon.Type, type);
            }
            Assert.AreEqual(weaponList.Count, 21);
        }