From 694b372f47a893077a413c8c9637ef61245f3f84 Mon Sep 17 00:00:00 2001 From: Joshua Soberg Date: Fri, 6 Dec 2024 16:31:48 -0500 Subject: [PATCH] Add get row,col test --- .../com/soberg/aoc/utlities/datastructures/Grid2DTest.kt | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/test/kotlin/com/soberg/aoc/utlities/datastructures/Grid2DTest.kt b/src/test/kotlin/com/soberg/aoc/utlities/datastructures/Grid2DTest.kt index 368c1e1..c1d8366 100644 --- a/src/test/kotlin/com/soberg/aoc/utlities/datastructures/Grid2DTest.kt +++ b/src/test/kotlin/com/soberg/aoc/utlities/datastructures/Grid2DTest.kt @@ -39,6 +39,12 @@ class Grid2DTest { .isEqualTo(333) } + @Test + fun `return expected element for get row, col`() { + assertThat(testGrid[3, 3]) + .isEqualTo(4444) + } + @Test fun `return expected element for elementAt`() { val actual = testGrid.elementAt(Location(2, 2), Direction.NorthWest, 2)