public void TestFetchSpell() { SpellBook myBook = new SpellBook (); Spell testSpell = new Heal ("Test spell"); myBook.AddSpell (testSpell); Assert.AreEqual (testSpell, myBook [0]); }
public void TestFetchSpell() { SpellBook myBook = new SpellBook(); Spell testSpell = new Heal("Test spell"); myBook.AddSpell(testSpell); Assert.AreEqual(testSpell, myBook [0]); }
public void TestRemoveSpell() { SpellBook myBook = new SpellBook (); Spell mySpell1 = new Teleport ("Sean's Teleporter"); Spell mySpell2 = new Heal ("Tom's Healer"); Spell mySpell3 = new Invisibilty ("Ian's Invisibilty"); myBook.AddSpell (mySpell1); myBook.AddSpell (mySpell2); myBook.AddSpell (mySpell3); Assert.AreEqual (3, myBook.SpellCount); myBook.RemoveSpell (mySpell2); Assert.AreEqual (2, myBook.SpellCount); }
public void TestRemoveSpell() { SpellBook myBook = new SpellBook(); Spell mySpell1 = new Teleport("Sean's Teleporter"); Spell mySpell2 = new Heal("Tom's Healer"); Spell mySpell3 = new Invisibilty("Ian's Invisibilty"); myBook.AddSpell(mySpell1); myBook.AddSpell(mySpell2); myBook.AddSpell(mySpell3); Assert.AreEqual(3, myBook.SpellCount); myBook.RemoveSpell(mySpell2); Assert.AreEqual(2, myBook.SpellCount); }
public void TestHealCast() { Spell s = new Heal("Heal"); StringAssert.IsMatch("Ahhh... you feel better", s.Cast()); }
public void TestHealCast() { Spell s = new Heal ("Heal"); StringAssert.IsMatch ("Ahhh... you feel better", s.Cast ()); }