diff options
author | MarcoFalke <falke.marco@gmail.com> | 2018-11-20 18:41:32 -0500 |
---|---|---|
committer | MarcoFalke <falke.marco@gmail.com> | 2018-11-20 19:51:49 -0500 |
commit | fa21ca09a807e18476babe2651ad62df6477bbf0 (patch) | |
tree | 539e5c07937b9d82f5e8c59a199a2bd3570a0aa1 /src/test/dbwrapper_tests.cpp | |
parent | 6d58a5c3b05585b01c960776e00856637ff1794d (diff) | |
download | bitcoin-fa21ca09a807e18476babe2651ad62df6477bbf0.tar.xz |
test: Add BOOST_REQUIRE to getters returning optional
Diffstat (limited to 'src/test/dbwrapper_tests.cpp')
-rw-r--r-- | src/test/dbwrapper_tests.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/test/dbwrapper_tests.cpp b/src/test/dbwrapper_tests.cpp index 9957ac074b..1034d4ade2 100644 --- a/src/test/dbwrapper_tests.cpp +++ b/src/test/dbwrapper_tests.cpp @@ -102,15 +102,15 @@ BOOST_AUTO_TEST_CASE(dbwrapper_iterator) char key_res; uint256 val_res; - it->GetKey(key_res); - it->GetValue(val_res); + BOOST_REQUIRE(it->GetKey(key_res)); + BOOST_REQUIRE(it->GetValue(val_res)); BOOST_CHECK_EQUAL(key_res, key); BOOST_CHECK_EQUAL(val_res.ToString(), in.ToString()); it->Next(); - it->GetKey(key_res); - it->GetValue(val_res); + BOOST_REQUIRE(it->GetKey(key_res)); + BOOST_REQUIRE(it->GetValue(val_res)); BOOST_CHECK_EQUAL(key_res, key2); BOOST_CHECK_EQUAL(val_res.ToString(), in2.ToString()); |