Skip to content

Commit

Permalink
Update LedgerData_test.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
dangell7 authored and RichardAH committed Mar 24, 2024
1 parent e232b6e commit 20a0f3a
Showing 1 changed file with 1 addition and 23 deletions.
24 changes: 1 addition & 23 deletions src/test/rpc/LedgerData_test.cpp
Expand Up @@ -305,28 +305,6 @@ class LedgerData_test : public beast::unit_test::suite
}
}

STTx
createUNLReportTx(
LedgerIndex seq,
PublicKey const& importKey,
PublicKey const& valKey)
{
auto fill = [&](auto& obj) {
obj.setFieldU32(sfLedgerSequence, seq);
obj.set(([&]() {
auto inner = std::make_unique<STObject>(sfActiveValidator);
inner->setFieldVL(sfPublicKey, valKey);
return inner;
})());
obj.set(([&]() {
auto inner = std::make_unique<STObject>(sfImportVLKey);
inner->setFieldVL(sfPublicKey, importKey);
return inner;
})());
};
return STTx(ttUNL_REPORT, fill);
}

void
testLedgerType()
{
Expand Down Expand Up @@ -497,7 +475,7 @@ class LedgerData_test : public beast::unit_test::suite
// insert a ttUNL_REPORT pseudo into the open ledger
env.app().openLedger().modify(
[&](OpenView& view, beast::Journal j) -> bool {
STTx tx = createUNLReportTx(
STTx tx = test::unl::createUNLReportTx(
env.current()->seq() + 1, ivlKeys[0], vlKeys[0]);
uint256 txID = tx.getTransactionID();
auto s = std::make_shared<ripple::Serializer>();
Expand Down

0 comments on commit 20a0f3a

Please sign in to comment.