예제 #1
0
        public void NavigatorDiscoversAllUnknownNodes()
        {
            const string want     = @"
-------------------
|     |     |     |
-------------------
|     |     |     |
-------------------
|     |     |     |
-------------------
";
            var          grid     = SetupZoneMap.SetupSmallGrid();
            var          traveler = new Traveler();

            traveler.CurrentZone = new Zone("test")
            {
                Map = grid
            };
            traveler.Position = Vector3.One;

            traveler.DiscoverAllNodes();


            Assert.Empty(traveler.CurrentZone.Map.UnknownNodes);

            string got = grid.PrintKnown();

            Assert.Equal(want, got);
        }