public void Select_NullTest() { var grid = new GridState { CellsMatrix = Utils.BuildCellMatrix(3, 3) }; grid.CellsMatrix[1, 2] = null; var area = new CellArea() { RowIndex = 1, ColumnIndex = 2 }; Assert.AreEqual(0, area.Select(grid).Count()); }
public void Select_Test() { var grid = new GridState { CellsMatrix = Utils.BuildCellMatrix(3, 3) }; var area = new CellArea() { RowIndex = 1, ColumnIndex = 2 }; Assert.AreSame( grid.CellsMatrix[1, 2], area.Select(grid).Single() ); }