test: improve assertion for SRD max weight test

Previously, the assertion only showed that a result was found, however
made no assertion about the quality of the result.

Remove comment about what UTXOs are selected and what are not
since the test does not reflect that.

Co-authored-by: Mark "Murch" Erhardt <murch@murch.one>
This commit is contained in:
yancy 2025-07-23 19:43:32 -05:00
parent 5ad79b2035
commit cc33e45789

View File

@ -1223,7 +1223,7 @@ BOOST_AUTO_TEST_CASE(srd_tests)
{
// ################################################################################################################
// 3) Test selection when some coins surpass the max allowed weight while others not. --> must find a good solution
// 3) Test that SRD result does not exceed the max weight
// ################################################################################################################
CAmount target = 25.33L * COIN;
int max_selection_weight = 10000; // WU
@ -1238,6 +1238,7 @@ BOOST_AUTO_TEST_CASE(srd_tests)
return available_coins;
});
BOOST_CHECK(res);
BOOST_CHECK(res->GetWeight() <= max_selection_weight);
}
}