public void Apply_useHeathPoitionToGetMaxLife() { var healthPotion = new TestItems().HealthPotion; var injuerdHuman = new TestCharacters().InjuerdHuman; healthPotion.Apply(injuerdHuman); healthPotion.Apply(injuerdHuman); injuerdHuman.CurrentFluentAttributes.LifePoints.Should().Be(15); }
public void Apply_useHeathPoitionOnWrongCharacter() { var healthPotion = new TestItems().HealthPotion; var wolf = new TestCharacters().Wolf; Assert.Throws <WrongRequirementException>(() => healthPotion.Apply(wolf)); }
public void Apply_useHeathPoitionOnHealthyCharcater() { var healthPotion = new TestItems().HealthPotion; var elve = new TestCharacters().Elve; healthPotion.Apply(elve); elve.CurrentFluentAttributes.LifePoints.Should().Be(13); }
public void Apply_useHeathPoitionOnEqipedCharcater() { var healthPotion = new TestItems().HealthPotion; var elve = new TestCharacters().Elve; var amuelet = new TestItems().ElvishAmulet; elve.Eqip(amuelet); healthPotion.Apply(elve); elve.CurrentFluentAttributes.LifePoints.Should().Be(18); }
public void Apply_useHeathPoitionDependsOnModifiedFluidAttributes() { var healthPotion = new TestItems().HealthPotion; var elve = Substitute.For <Character>(); var baseElve = new TestCharacters().Elve; elve.BaseFluentAttributes = baseElve.BaseFluentAttributes; elve.CurrentFluentAttributes = baseElve.CurrentFluentAttributes; elve.Features = baseElve.Features; elve.GetModifiedFluentAttributes().Returns(new CharacterFluentAttributes { LifePoints = 20 }); healthPotion.Apply(elve); elve.CurrentFluentAttributes.LifePoints.Should().Be(19); }