Skip to content
Bitcoin Roots

v29.4-roots.4 · Commit 34: [PATCH 34/37] test(mining): use locale-independent priority size formatting

src/test/miner_tests.cpp

Before: src/test/miner_tests.cpp · After: src/test/miner_tests.cpp

File metadata
index 57409da0c0894de3bee45b82398d1bb2ecf292f9..22b55dcc2982752a71ac0014679887e35c1b53e3 100644

Download original patch · Release notes

Diff rows 1–22 of 22. Line numbers refer to the original before/after files.

+ Added− RemovedUnmarked lines are context.

Scroll the code area horizontally to read long lines. The two line-number columns refer to before and after.

src/test/miner_tests.cpp CHANGED
@@ -20,6 +20,7 @@
20
20
  #include <util/check.h>
21
21
  #include <util/feefrac.h>
22
22
  #include <util/strencodings.h>
23
+ #include <util/string.h>
23
24
  #include <util/time.h>
24
25
  #include <util/translation.h>
25
26
  #include <validation.h>
@@ -28,7 +29,6 @@
28
29
  #include <test/util/setup_common.h>
29
30
 
30
31
  #include <memory>
31
- #include <string>
32
32
  #include <vector>
33
33
 
34
34
  #include <boost/test/unit_test.hpp>
@@ -778,7 +778,7 @@ void MinerTestingSetup::TestPriorityPhaseStaleAncestors(const CScript& scriptPub
778
778
 
779
779
  // The assembler reserves 1000 bytes before adding transactions;
780
780
  // end the priority phase immediately after including the parents.
781
- gArgs.ForceSetArg("-blockprioritysize", std::to_string(1000 + priority_tx_size));
781
+ gArgs.ForceSetArg("-blockprioritysize", util::ToString(1000 + priority_tx_size));
782
782
  const auto priority_template = BlockAssembler{m_node.chainman->ActiveChainstate(), &tx_mempool, options}.CreateNewBlock();
783
783
  BOOST_REQUIRE(priority_template);
784
784
  BOOST_REQUIRE_EQUAL(priority_template->block.vtx.size(), parent_count + 2);