Merge branch 'v0.12.1.x' of https://github.com/dashpay/dash into v0.12.1.x
This commit is contained in:
commit
432d5e7ac6
@ -19,20 +19,20 @@ BOOST_AUTO_TEST_SUITE(Checkpoints_tests)
|
||||
BOOST_AUTO_TEST_CASE(sanity)
|
||||
{
|
||||
uint256 p88805 = uint256("0x00000000001392f1652e9bf45cd8bc79dc60fe935277cd11538565b4a94fa85f");
|
||||
uint256 p217752 = uint256("0x00000000000a7baeb2148272a7e14edf5af99a64af456c0afc23d15a0918b704");
|
||||
uint256 p107996 = uint256("0x00000000000a23840ac16115407488267aa3da2b9bc843e301185b7d17e4dc40");
|
||||
BOOST_CHECK(Checkpoints::CheckBlock(88805, p88805));
|
||||
BOOST_CHECK(Checkpoints::CheckBlock(217752, p217752));
|
||||
BOOST_CHECK(Checkpoints::CheckBlock(107996, p107996));
|
||||
|
||||
|
||||
// Wrong hashes at checkpoints should fail:
|
||||
BOOST_CHECK(!Checkpoints::CheckBlock(88805, p217752));
|
||||
BOOST_CHECK(!Checkpoints::CheckBlock(217752, p88805));
|
||||
BOOST_CHECK(!Checkpoints::CheckBlock(88805, p107996));
|
||||
BOOST_CHECK(!Checkpoints::CheckBlock(107996, p88805));
|
||||
|
||||
// ... but any hash not at a checkpoint should succeed:
|
||||
BOOST_CHECK(Checkpoints::CheckBlock(88805+1, p217752));
|
||||
BOOST_CHECK(Checkpoints::CheckBlock(217752+1, p88805));
|
||||
BOOST_CHECK(Checkpoints::CheckBlock(88805+1, p107996));
|
||||
BOOST_CHECK(Checkpoints::CheckBlock(107996+1, p88805));
|
||||
|
||||
BOOST_CHECK(Checkpoints::GetTotalBlocksEstimate() >= 217752);
|
||||
BOOST_CHECK(Checkpoints::GetTotalBlocksEstimate() >= 107996);
|
||||
}
|
||||
|
||||
BOOST_AUTO_TEST_SUITE_END()
|
||||
|
Loading…
Reference in New Issue
Block a user