From 9f9570e2c051b8f412040f36a99b35d8da264c6d Mon Sep 17 00:00:00 2001 From: Hind Montassif Date: Mon, 1 Jul 2024 18:08:32 +0200 Subject: [PATCH] Uncomment test after rebase --- test/test_variable_size_binary_layout.cpp | 42 +++++++++++------------ 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/test/test_variable_size_binary_layout.cpp b/test/test_variable_size_binary_layout.cpp index 568abba6..8c79614c 100644 --- a/test/test_variable_size_binary_layout.cpp +++ b/test/test_variable_size_binary_layout.cpp @@ -134,27 +134,27 @@ namespace sparrow CHECK_EQ(iter, brange.end()); } -// TEST_CASE_FIXTURE(vs_binary_fixture, "const_iterator") -// { -// layout_type l(m_data); -// auto cref0 = l[0]; -// auto cref2 = l[2]; -// -// auto iter = l.cbegin(); -// // CHECK_EQ(*iter, std::make_optional(cref0.value())); -// -// ++iter; -// CHECK(!iter->has_value()); -// -// ++iter; -// CHECK_EQ(iter->value(), cref2.value()); -// -// iter++; -// CHECK_EQ(iter, l.cend()); -// -// iter -= 3; -// CHECK_EQ(iter, l.cbegin()); -// } + TEST_CASE_FIXTURE(vs_binary_fixture, "const_iterator") + { + const layout_type l(m_data); + auto cref0 = l[0]; + auto cref2 = l[2]; + + auto iter = l.cbegin(); + CHECK_EQ(*iter, std::make_optional(cref0.value())); + + ++iter; + CHECK(!iter->has_value()); + + ++iter; + CHECK_EQ(iter->value(), cref2.value()); + + iter++; + CHECK_EQ(iter, l.cend()); + + iter -= 3; + CHECK_EQ(iter, l.cbegin()); + } TEST_CASE("vs_binary_reference") {