示例#1
0
        public void CalculateDamageSpellsC()
        {
            ICard fireSpell = new SpellCard(
                90, DamageType.Fire, new List <ISpeciality>(), log
                );
            ICard waterSpell = new SpellCard(
                5, DamageType.Water, new List <ISpeciality>(), log
                );

            var fireSpellResult  = fireSpell.CalculateDamage(waterSpell).Value;
            var waterSpellResult = waterSpell.CalculateDamage(fireSpell).Value;

            Assert.AreEqual(45, fireSpellResult);
            Assert.AreEqual(10, waterSpellResult);
        }
示例#2
0
        public void CalculateDamageMixedC()
        {
            ICard regularSpell = new SpellCard(
                10, DamageType.Normal, new List <ISpeciality>(), log
                );
            ICard waterGoblin = new MonsterCard(
                10, DamageType.Water, MonsterType.Goblin, new List <ISpeciality>(),
                new List <IEffect>(), log
                );

            var regularSpellResult = regularSpell.CalculateDamage(waterGoblin).Value;
            var waterGoblinResult  = waterGoblin.CalculateDamage(regularSpell).Value;

            Assert.AreEqual(20, regularSpellResult);
            Assert.AreEqual(5, waterGoblinResult);
        }
示例#3
0
        public void CalculateDamageMixedD()
        {
            ICard regularSpell = new SpellCard(
                10, DamageType.Normal, new List <ISpeciality>(), log
                );
            ICard regularKnight = new MonsterCard(
                15, DamageType.Normal, MonsterType.Goblin, new List <ISpeciality>(),
                new List <IEffect>(), log
                );

            var regularSpellResult  = regularSpell.CalculateDamage(regularKnight).Value;
            var regularKnightResult = regularKnight.CalculateDamage(regularSpell).Value;

            Assert.AreEqual(10, regularSpellResult);
            Assert.AreEqual(15, regularKnightResult);
        }
示例#4
0
        public void CalculateDamageMixedA()
        {
            ICard fireSpell = new SpellCard(
                10, DamageType.Fire, new List <ISpeciality>(), log
                );
            ICard waterGoblin = new MonsterCard(
                10, DamageType.Water, MonsterType.Goblin, new List <ISpeciality>(),
                new List <IEffect>(), log
                );

            var fireSpellResult   = fireSpell.CalculateDamage(waterGoblin).Value;
            var waterGoblinResult = waterGoblin.CalculateDamage(fireSpell).Value;

            Assert.AreEqual(5, fireSpellResult);
            Assert.AreEqual(20, waterGoblinResult);
        }