Fixed miner test values, gave constants for less error-prone values. #7807

pull instagibbs wants to merge 2 commits into bitcoin:master from instagibbs:mintest changing 1 files +29 −24
  1. instagibbs commented at 3:20 PM on April 4, 2016: member

    Based on discussion in #7784 I decided to do a bit more cleanup.

  2. instagibbs commented at 3:22 PM on April 4, 2016: member

    Doing this I noticed yet another mis-typed value on https://github.com/bitcoin/bitcoin/pull/7807/files#diff-5c64500485fda76388a86c95c0059585L173 , so it seemed worthwhile.

  3. instagibbs force-pushed on Apr 4, 2016
  4. jonasschnelli added the label Tests on Apr 4, 2016
  5. MarcoFalke commented at 4:12 PM on April 4, 2016: member

    That's clearer. Concept ACK 11679ca

  6. laanwj commented at 5:39 AM on April 5, 2016: member

    utACK

  7. btcdrak commented at 7:59 AM on April 5, 2016: contributor

    utACK

  8. in src/test/miner_tests.cpp:None in 11679ca764 outdated
     171 | @@ -167,13 +172,13 @@ BOOST_AUTO_TEST_CASE(CreateNewBlock_validity)
     172 |          tx.vin[0].scriptSig << vchData << OP_DROP;
     173 |      tx.vin[0].scriptSig << OP_1;
     174 |      tx.vin[0].prevout.hash = txFirst[0]->GetHash();
     175 | -    tx.vout[0].nValue = 5000000000LL;
     176 | +    tx.vout[0].nValue = BLOCKSUBSIDY;
     177 |      for (unsigned int i = 0; i < 128; ++i)
     178 |      {
     179 | -        tx.vout[0].nValue -= 10000000;
    


    paveljanik commented at 8:40 AM on April 6, 2016:

    10*LOWFEE?

  9. in src/test/miner_tests.cpp:None in 11679ca764 outdated
     215 | @@ -211,7 +216,7 @@ BOOST_AUTO_TEST_CASE(CreateNewBlock_validity)
     216 |      tx.vout[0].nValue = 0;
     217 |      hash = tx.GetHash();
     218 |      // give it a fee so it'll get mined
     219 | -    mempool.addUnchecked(hash, entry.Fee(100000).Time(GetTime()).SpendsCoinbase(false).FromTx(tx));
    


    paveljanik commented at 8:40 AM on April 6, 2016:

    LOWFEE/10?

  10. paveljanik commented at 8:42 AM on April 6, 2016: contributor

    As you are not replacing constants only, can you please change it so that you first replace constants unchanged and then do the changes, ie two commits? It will make review much easier...

  11. instagibbs force-pushed on Apr 6, 2016
  12. instagibbs commented at 12:30 PM on April 6, 2016: member
  13. paveljanik commented at 9:01 AM on April 7, 2016: contributor

    @instagibbs Reading this thoroughly, I think we could also define constants in the term of COIN and CENT, it could be even more descriptive.

  14. instagibbs force-pushed on Apr 7, 2016
  15. Gave miner test values constants for less error-prone values. 617deeb06e
  16. Corrected values f8536a62c3
  17. instagibbs force-pushed on Apr 7, 2016
  18. MarcoFalke merged this on Apr 29, 2016
  19. MarcoFalke closed this on Apr 29, 2016

  20. MarcoFalke referenced this in commit 0ad1041904 on Apr 29, 2016
  21. codablock referenced this in commit 1c90ea2dfe on Sep 16, 2017
  22. codablock referenced this in commit ca233bffdc on Sep 19, 2017
  23. codablock referenced this in commit d975013160 on Dec 20, 2017
  24. DrahtBot locked this on Sep 8, 2021

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-27 03:16 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me