Beispiel #1
0
        public void Scouting_ShouldNotSeeScoutedHero_OnNextTurn()
        {
            client.ScoutHero();
            var data = client.Wait(0.1);

            data.Map.Objects
            .FirstOrDefault(x => x.Hero != null && x.Hero.Name == "Right")
            .Should().BeNull();
        }
        public void Scouting_OtherHero_ShouldBeVisible_WhenScoutingHero()
        {
            var data = client.ScoutHero();

            data.Map.Objects
            .Where(x => x.Location.ToLocation().EuclideanDistance(Location.Zero) > HommRules.Current.HeroViewRadius)
            .Where(x => x.Hero != null)
            .Should().NotBeEmpty();

            data.Map.Objects
            .Where(x => x.Location.ToLocation().EuclideanDistance(Location.Zero) > HommRules.Current.HeroViewRadius)
            .Single(x => x.Hero != null)
            .Hero.Name.Should().Be("Right");
        }