示例#1
0
 public void GivenAPladinLevel_SpellArrayIsReturned(int level, int[] expectedSpells)
 {
     PlayerClass player = new Paladin();
     player.AssignLevel(level);
     player.GetClassSpellsPerDay();
     int[] actual = player.Magic.ClassSpellsPerDay;
     Assert.AreEqual(expectedSpells, actual);
 }
示例#2
0
 public void GivenALevel_ArrayOfClassSkillsReturned(int level, string[] expected)
 {
     PlayerClass pc = new Paladin();
     pc.AssignLevel(level);
     pc.AssignClassAbilties();
     string[] actual = pc.ClassAbilities;
     Assert.AreEqual(expected, actual);
 }
示例#3
0
 public void PaladinReturnAlignments()
 {
     PlayerClass player = new Paladin();
     string[] expected = {"Lawful Good"};
     string[] actual = player.ClassAlignments;
     Assert.AreEqual(expected,actual);
 }
示例#4
0
        public void Given_Then_Returned()
        {
            // Arrange
            PlayerClass pc = new Paladin();

            // Act
            pc.GetSpellDifficultyClass();
            int[] actual = pc.Magic.SpellDC;

            // Assert
            Assert.IsNull(actual);
        }
示例#5
0
 public void CreatePlayerClass(string playerClass)
 {
     switch (playerClass)
     {
         case "Barbarian":
             PlayerClass = new Barbarian();
             break;
         case "Bard":
             PlayerClass = new Bard();
             break;
         case "Cleric":
             PlayerClass = new Cleric();
             break;
         case "Druid":
             PlayerClass = new Druid();
             break;
         case "Fighter":
             PlayerClass = new Fighter();
             break;
         case "Monk":
             PlayerClass = new Monk();
             break;
         case "Paladin":
             PlayerClass = new Paladin();
             break;
         case "Ranger":
             PlayerClass = new Ranger();
             break;
         case "Rogue":
             PlayerClass = new Rogue();
             break;
         case "Sorcerer":
             PlayerClass = new Sorcerer();
             break;
         case "Wizard":
             PlayerClass = new Wizard();
             break;
     }
 }
示例#6
0
 public void Init()
 {
     Paladin = new Paladin();
 }