diff --git a/src/test/java/inf112/fiasko/roborally/objects/BoardElementContainerTest.java b/src/test/java/inf112/fiasko/roborally/objects/BoardElementContainerTest.java new file mode 100644 index 0000000..7654fcb --- /dev/null +++ b/src/test/java/inf112/fiasko/roborally/objects/BoardElementContainerTest.java @@ -0,0 +1,27 @@ +package inf112.fiasko.roborally.objects; + +import inf112.fiasko.roborally.element_properties.Direction; +import inf112.fiasko.roborally.element_properties.Position; +import inf112.fiasko.roborally.element_properties.TileType; +import org.junit.Test; + +import static org.junit.Assert.assertEquals; + +public class BoardElementContainerTest { + + @Test + public void getObjectTest() { + Position pos = new Position(1,2); + Tile tile = new Tile(TileType.TILE, Direction.NORTH); + BoardElementContainer element = new BoardElementContainer<>(tile, pos); + assertEquals(tile, element.getObject()); + } + + @Test + public void getPositionTest() { + Position pos = new Position(1,2); + Tile tile = new Tile(TileType.TILE, Direction.NORTH); + BoardElementContainer element = new BoardElementContainer<>(tile, pos); + assertEquals(pos, element.getPosition()); + } +} \ No newline at end of file