Skip to content

Commit

Permalink
Replace string with string_view in some tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Hind-M committed Jul 2, 2024
1 parent 9f9570e commit 73c666e
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions test/test_variable_size_binary_layout.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ namespace sparrow

SUBCASE("inner_reference")
{
cref3.value() = std::string("unpreparedandmore");
cref3.value() = std::string_view("unpreparedandmore");

CHECK_EQ(cref0.value(), words[0]);
CHECK_EQ(cref1.value(), words[1]);
Expand All @@ -197,7 +197,7 @@ namespace sparrow

CHECK_EQ(cref0.value(), std::string("he"));
CHECK_EQ(cref1.value(), std::string("is"));
CHECK_EQ(cref2.value(), std::string(""));
CHECK_EQ(cref2.value(), std::string_view(""));
CHECK_EQ(cref3.value(), std::string("unpreparedandmore"));
}

Expand Down Expand Up @@ -235,8 +235,6 @@ namespace sparrow
CHECK_EQ(cref2.value(), std::string("a"));
CHECK_EQ(cref3.value(), std::string("replacement"));
}

// TODO add tests for the different overloads of operator = and ==
}
}
}

0 comments on commit 73c666e

Please sign in to comment.