aboutsummaryrefslogtreecommitdiff
path: root/tests/unit_tests/block_reward.cpp
diff options
context:
space:
mode:
authorRiccardo Spagni <ric@spagni.net>2014-10-08 21:38:55 +0200
committerRiccardo Spagni <ric@spagni.net>2014-10-08 21:38:55 +0200
commit1795c381c0537119cc26ae55b523f71ba029da79 (patch)
treed645a3bd987f4f2fdaa8e3eb4e5c8c48a720ec07 /tests/unit_tests/block_reward.cpp
parentminiupnpc static define change (diff)
downloadmonero-1795c381c0537119cc26ae55b523f71ba029da79.tar.xz
fixed unit tests
Diffstat (limited to 'tests/unit_tests/block_reward.cpp')
-rw-r--r--tests/unit_tests/block_reward.cpp19
1 files changed, 10 insertions, 9 deletions
diff --git a/tests/unit_tests/block_reward.cpp b/tests/unit_tests/block_reward.cpp
index bf6cc8c84..7ae088d97 100644
--- a/tests/unit_tests/block_reward.cpp
+++ b/tests/unit_tests/block_reward.cpp
@@ -53,23 +53,24 @@ namespace
TEST_F(block_reward_and_already_generated_coins, handles_first_values)
{
- TEST_ALREADY_GENERATED_COINS(0, 70368744177663);
- TEST_ALREADY_GENERATED_COINS(m_block_reward, 70368475742208);
- TEST_ALREADY_GENERATED_COINS(UINT64_C(2756434948434199641), 59853779316998);
+ // 17592186044415 from neozaru, confirmed by fluffypony
+ TEST_ALREADY_GENERATED_COINS(0, 17592186044415);
+ TEST_ALREADY_GENERATED_COINS(m_block_reward, 17592169267200);
+ TEST_ALREADY_GENERATED_COINS(UINT64_C(2756434948434199641), 14963444829249);
}
TEST_F(block_reward_and_already_generated_coins, correctly_steps_from_2_to_1)
{
- TEST_ALREADY_GENERATED_COINS(MONEY_SUPPLY - ((2 << 18) + 1), 2);
- TEST_ALREADY_GENERATED_COINS(MONEY_SUPPLY - (2 << 18) , 2);
- TEST_ALREADY_GENERATED_COINS(MONEY_SUPPLY - ((2 << 18) - 1), 1);
+ TEST_ALREADY_GENERATED_COINS(MONEY_SUPPLY - ((2 << 20) + 1), 2);
+ TEST_ALREADY_GENERATED_COINS(MONEY_SUPPLY - (2 << 20) , 2);
+ TEST_ALREADY_GENERATED_COINS(MONEY_SUPPLY - ((2 << 20) - 1), 1);
}
TEST_F(block_reward_and_already_generated_coins, handles_max)
{
- TEST_ALREADY_GENERATED_COINS(MONEY_SUPPLY - ((1 << 18) + 1), 1);
- TEST_ALREADY_GENERATED_COINS(MONEY_SUPPLY - (1 << 18) , 1);
- TEST_ALREADY_GENERATED_COINS(MONEY_SUPPLY - ((1 << 18) - 1), 0);
+ TEST_ALREADY_GENERATED_COINS(MONEY_SUPPLY - ((1 << 20) + 1), 1);
+ TEST_ALREADY_GENERATED_COINS(MONEY_SUPPLY - (1 << 20) , 1);
+ TEST_ALREADY_GENERATED_COINS(MONEY_SUPPLY - ((1 << 20) - 1), 0);
}
//--------------------------------------------------------------------------------------------------------------------