test: Add cost_of_change parameter assertions to bnb_search_test #18195

pull yancyribbens wants to merge 1 commits into bitcoin:master from yancyribbens:add-coinselection-cost-of-change-test-cases changing 1 files +13 −0
  1. yancyribbens commented at 8:18 AM on February 22, 2020: contributor

    If the cost_of_change variable is removed from the method body SelectCoinsBnB, there are currently no failing unit tests. This PR adds assertions about the behavior of the cost_of_change: If the cost of creating a change output is greater than what's leftover, then consume the output and create no change, otherwise, don't consume the output (no match found).

  2. fanquake added the label Tests on Feb 22, 2020
  3. MarcoFalke commented at 3:21 PM on February 22, 2020: member

    re-run ci

  4. MarcoFalke closed this on Feb 22, 2020

  5. MarcoFalke reopened this on Feb 22, 2020

  6. test: Add cost_of_change parameter assertions to bnb_search_test c72a11a1a0
  7. yancyribbens force-pushed on Feb 22, 2020
  8. yancyribbens commented at 5:16 PM on February 22, 2020: contributor

    removed second add_coin(1 * CENT, 1, actual_selection); as it's not needed for the last assertion.

  9. DrahtBot commented at 3:14 PM on February 24, 2020: member

    <!--e57a25ab6845829454e8d69fc972939a-->

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    <!--2502f1a698b3751726fa55edcda76cd3-->

    Coverage

    Coverage Change (pull 18195, 12fa66f329e969411251f81adf98c9b7c7b171ed) Reference (master, ab9de435880c9d77e4137b65050591ef2d14f809)
    Lines -0.0477 % 89.9398 %
    Functions -0.0888 % 85.8686 %
    Branches -0.0332 % 51.5553 %

    <sup>Updated at: 2020-02-24T15:14:56.775240.</sup>

  10. Binh0103 commented at 3:55 PM on February 24, 2020: none

    Perfect

  11. fanquake requested review from achow101 on Feb 28, 2020
  12. achow101 approved
  13. achow101 commented at 5:36 PM on February 28, 2020: member

    ACK c72a11a1a030036eb1fe4472086a9733731961ce

  14. MarcoFalke merged this on Feb 28, 2020
  15. MarcoFalke closed this on Feb 28, 2020

  16. sidhujag referenced this in commit 405c017457 on Feb 28, 2020
  17. jasonbcox referenced this in commit f67e38b0ef on Nov 10, 2020
  18. sidhujag referenced this in commit ea882113ec on Nov 10, 2020
  19. PastaPastaPasta referenced this in commit e11082b9e1 on Jun 27, 2021
  20. PastaPastaPasta referenced this in commit a43f0af7bd on Jun 28, 2021
  21. PastaPastaPasta referenced this in commit a05f813a1d on Jun 29, 2021
  22. PastaPastaPasta referenced this in commit c7ac7d46fc on Sep 17, 2021
  23. PastaPastaPasta referenced this in commit 44aef1f053 on Sep 18, 2021
  24. thelazier referenced this in commit b898edd07f on Sep 25, 2021
  25. DrahtBot locked this on Feb 15, 2022

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-25 00:14 UTC

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