Skip to content

Commit

Permalink
feat: add another test
Browse files Browse the repository at this point in the history
  • Loading branch information
DvdPlaat committed Feb 7, 2024
1 parent 81cf7bf commit f5b61c1
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions Source/Tests/ScoreTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,12 @@ public class ScoreTests
{3,1,1,3,1,1 },
{0,1,1,1,1,0 },
};
static readonly int[,] GridF =
{
{3,3},
{1,1},
{2,2}
};

private static int CalculatePoints(int[,] grid, int[,] state)
{
Expand Down Expand Up @@ -115,4 +121,17 @@ public void TestBigGrid()

Assert.Equal(15, CalculatePoints(Grids.GridB, state));
}

[Fact]
public void TestWeirdGrid()
{
int[,] state =
{
{2,2 },
{4,4 },
{4,4 },
};

Assert.Equal(15, CalculatePoints(GridF, state));
}
}

0 comments on commit f5b61c1

Please sign in to comment.