Example #1
0
        public void ExploreDifferentRowsOnce()
        {
            var       minefield                = Minefield.Empty(2, 3);
            Minefield exploredMinefield        = minefield.Explore(new Coordinates(0, 1));
            Minefield furtherExploredMinefield = exploredMinefield.Explore(new Coordinates(1, 0));

            Assert.AreEqual(true, furtherExploredMinefield.IsExplored(1, 0));
            Assert.AreEqual(true, furtherExploredMinefield.IsExplored(0, 1));
        }
Example #2
0
        public void ExploringARowTwiceWorks()
        {
            var       minefield                = Minefield.Empty(2, 3);
            Minefield exploredMinefield        = minefield.Explore(new Coordinates(0, 1));
            Minefield furtherExploredMinefield = exploredMinefield.Explore(new Coordinates(0, 0));

            Assert.AreEqual(true, furtherExploredMinefield.IsExplored(0, 0));
            Assert.AreEqual(true, furtherExploredMinefield.IsExplored(0, 1));
        }