public void CampActionValidInWilderness() { actor.Enter <Location>(wilderness); var action = new CampAction(actor); Assert.AreEqual(ActionOutcome.Progress(), action.Execute(dryRun: true)); }
public void CannotCampOutsideOfWilderness(bool dryRun) { actor.Enter <Location>(building); var action = new CampAction(actor); Assert.AreEqual(ActionStatus.Failed, action.Execute(dryRun).Status); }
public void CanCampInWilderness() { actor.Enter <Location>(wilderness); var action = new CampAction(actor); for (int i = 0; i < 10; i++) { Assert.AreEqual(ActionOutcome.Progress(), action.Execute(dryRun: false)); } Assert.IsFalse(wilderness.Get <Wilderness>().HasCampsite); Assert.AreEqual(ActionOutcome.Success(), action.Execute(dryRun: false)); Assert.IsTrue(wilderness.Get <Wilderness>().HasCampsite); }