Example #1
0
        public void Populate_GetValueTest(string populateText, int getRow, int getCol, char expectedValue)
        {
            var grid  = new StringSearchGrid(populateText);
            var value = grid.GetValue(getRow, getCol);

            value.Should().Be(expectedValue);
        }
Example #2
0
        public void SizeConstructor_AllValuesNull(int width, int height)
        {
            var grid = new StringSearchGrid(width, height);

            for (int x = 0; x < width; x++)
            {
                for (int y = 0; y < height; y++)
                {
                    grid.GetValue(y, x).Should().BeNull();
                }
            }
        }