diff options
-rw-r--r-- | Tests/AK/TestIntrusiveList.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/Tests/AK/TestIntrusiveList.cpp b/Tests/AK/TestIntrusiveList.cpp index f75db9afb7..005642a9b6 100644 --- a/Tests/AK/TestIntrusiveList.cpp +++ b/Tests/AK/TestIntrusiveList.cpp @@ -47,6 +47,13 @@ TEST_CASE(enumeration) actual_size++; } EXPECT_EQ(expected_size, actual_size); + + size_t reverse_actual_size = 0; + for (auto it = list.rbegin(); it != list.rend(); ++it) { + reverse_actual_size++; + } + EXPECT_EQ(expected_size, reverse_actual_size); + while (auto elem = list.take_first()) { delete elem; } |