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