First test good
This commit is contained in:
@@ -247,3 +247,13 @@ TEST_CASE("Find 1 value not present", "[linkedlist]") {
|
||||
auto result = list.find(80);
|
||||
REQUIRE(result.error() == LinkedListErr::LINKEDLIST_NOT_FOUND);
|
||||
}
|
||||
|
||||
TEST_CASE("Insert at empty list", "[linkedlist]") {
|
||||
LinkedList<int> list = {};
|
||||
|
||||
REQUIRE(list.len() == 0);
|
||||
|
||||
list.insert(0, 8);
|
||||
REQUIRE(list.len() == 1);
|
||||
REQUIRE(list.get(0) == 8);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user