Ejemplo n.º 1
0
        public void CanBuyHP()
        {
            modelmock.Object.Hero.Hp--;

            // Arrange
            int expectedherohp   = modelmock.Object.Hero.Hp + 1;
            int expectedherocash = modelmock.Object.Hero.Cash - modelmock.Object.HPPrice;

            // ACT
            gameLogic.BuyHP();

            // ASSERT
            Assert.That(modelmock.Object.Hero.Hp, Is.EqualTo(expectedherohp));
            Assert.That(modelmock.Object.Hero.Cash, Is.EqualTo(expectedherocash));
        }