diff options
author | fanquake <fanquake@gmail.com> | 2021-07-09 13:12:51 +0800 |
---|---|---|
committer | fanquake <fanquake@gmail.com> | 2021-08-04 19:48:24 +0800 |
commit | f7752adba5dd35fccd3f2144cfcf03538ebf275b (patch) | |
tree | deb01f8d53f0b85bf5cf35b6b045bd869c8eac02 /src/test/util_tests.cpp | |
parent | 5ef2738089efd396186775ad23aaec71ea44ebb1 (diff) | |
download | bitcoin-f7752adba5dd35fccd3f2144cfcf03538ebf275b.tar.xz |
util: check MoneyRange() inside ParseMoney()
Diffstat (limited to 'src/test/util_tests.cpp')
-rw-r--r-- | src/test/util_tests.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/test/util_tests.cpp b/src/test/util_tests.cpp index b953df580f..4f9d10cf1d 100644 --- a/src/test/util_tests.cpp +++ b/src/test/util_tests.cpp @@ -1226,7 +1226,6 @@ BOOST_AUTO_TEST_CASE(util_ParseMoney) BOOST_CHECK_EQUAL(ParseMoney("12345.6789").value(), (COIN/10000)*123456789); - BOOST_CHECK_EQUAL(ParseMoney("100000000.00").value(), COIN*100000000); BOOST_CHECK_EQUAL(ParseMoney("10000000.00").value(), COIN*10000000); BOOST_CHECK_EQUAL(ParseMoney("1000000.00").value(), COIN*1000000); BOOST_CHECK_EQUAL(ParseMoney("100000.00").value(), COIN*100000); @@ -1252,6 +1251,7 @@ BOOST_AUTO_TEST_CASE(util_ParseMoney) BOOST_CHECK_EQUAL(ParseMoney(" 0.00000001").value(), COIN/100000000); // Parsing amount that can not be represented should fail + BOOST_CHECK(!ParseMoney("100000000.00")); BOOST_CHECK(!ParseMoney("0.000000001")); // Parsing empty string should fail |