diff --git a/src/test/java/xyz/joethei/studium/algodat/vorlesung/Blatt2Test.java b/src/test/java/xyz/joethei/studium/algodat/vorlesung/Blatt2Test.java index 7c1d860..994bf63 100644 --- a/src/test/java/xyz/joethei/studium/algodat/vorlesung/Blatt2Test.java +++ b/src/test/java/xyz/joethei/studium/algodat/vorlesung/Blatt2Test.java @@ -1,5 +1,6 @@ package xyz.joethei.studium.algodat.vorlesung; +import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Test; import xyz.joethei.studium.algodat.praktikum.blatt2.List; import xyz.joethei.studium.algodat.praktikum.blatt2.RingList; @@ -7,6 +8,7 @@ import xyz.joethei.studium.algodat.praktikum.blatt2.RingList; import java.util.Optional; import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertTrue; class Blatt2Test { @@ -37,5 +39,17 @@ class Blatt2Test { assertEquals(10, rList.size()); } + @Disabled + @Test + void remove() { + List rList = new RingList<>(); + for (int i = 1; i <= 10; i++) { + rList.add(i * i); + } + assertEquals(Optional.of(36), Optional.ofNullable(rList.remove(5))); + assertEquals(9, rList.size()); + assertTrue(rList.get(5) != 36); + } + } \ No newline at end of file