Skip to content

Commit

Permalink
Use boost::hash instead of boost::hash_value (properly tests #290 use…
Browse files Browse the repository at this point in the history
… case)
  • Loading branch information
igaztanaga committed Sep 30, 2024
1 parent bf029b6 commit 0a62c97
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions test/string_view_compat_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -281,9 +281,11 @@ void hash_test()

const boost::container::string s1 = "0125925123";
const boost::container::string s2 = "25925123";
typedef boost::hash<boost::container::string> shash_t;
typedef boost::hash<StringViewType> svhash_t;

BOOST_TEST(boost::hash_value(s1) == boost::hash_value(StringViewType(s1)));
BOOST_TEST(boost::hash_value(s2) == boost::hash_value(StringViewType(s2)));
BOOST_TEST(shash_t()(s1) == svhash_t()(StringViewType(s1)));
BOOST_TEST(shash_t()(s2) == svhash_t()(StringViewType(s2)));
}

#else
Expand Down

0 comments on commit 0a62c97

Please sign in to comment.