public void AbortingToAction_CharacterCannotAbortAgainUntilNextPhaseStarts()
        {
            //arrange
            CombatSequence      sequence = Factory.SequenceWithFastMediumAndSlowCharacters;
            HeroSystemCharacter other    = Factory.Factory.BaseCharacter;

            other.DEX.MaxValue = 9;
            sequence.AddCharacter(other);

            sequence.StartCombat();
            HeroSystemCharacter attacker = sequence.ActivePhase.Character;

            attacker.DEX.MaxValue = 20;

            HeroSystemCharacter defender = sequence.ActiveSegment.PhaseNextInDexOrder.Character;

            defender.DEX.MaxValue = 10;
            TestAbortableManuever abortableManuever = new TestAbortableManuever("Abortable Manuever", defender);



            Attack attack = attacker.Manuevers["Strike"] as Attack;

            attack?.Target(defender);


            defender.Manuevers["Abort"].Perform();
            defender.Manuevers["Abortable Manuever"].Perform();

            Assert.AreEqual(false, defender.Manuevers["Abort"].CanPerform);


            Assert.AreEqual(sequence.InterruptedPhase.Character, attacker);
        }
 public void Given()
 {
     Sequence = new CombatSequence();
     Sequence.StartCombat();
     Character = Factory.BaseCharacter;
     Character.SPD.MaxValue = 6;
     Sequence.AddCharacter(Character);
     Sequence.StartCombat();
 }
        public void CharacterPerformsFullPhaseAction_CharacterPhaseIsOver()
        {
            //arrange
            CombatSequence      sequence = Factory.SequenceWithCharacterWithMixOfFullAndHalfPhaseManuevers;
            HeroSystemCharacter nextC    = Factory.Factory.BaseCharacter;

            nextC.DEX.MaxValue = 5;
            sequence.AddCharacter(Factory.Factory.BaseCharacter);

            sequence.StartCombat();
            Phase phase = sequence.ActivePhase;
            HeroSystemCharacter character = phase.Character;
            Phase nextPhase = sequence.NextCombatPhase;

            IManuever fullManuever = character.Manuevers["Sample Full"];

            //act
            fullManuever.Perform();

            //assert
            Assert.AreEqual(phase.Active, false);
            Assert.AreEqual(sequence.ActivePhase, nextPhase);
        }