21#include <test/jtx/PathSet.h>
23#include <xrpld/app/paths/Flow.h>
24#include <xrpld/app/paths/detail/Steps.h>
25#include <xrpld/core/Config.h>
26#include <xrpld/ledger/PaymentSandbox.h>
27#include <xrpld/ledger/Sandbox.h>
29#include <xrpl/basics/contract.h>
30#include <xrpl/protocol/Feature.h>
46 return sle->isFlag(flag);
48 Throw<std::runtime_error>(
"No line in getTrustFlag");
60 auto const alice =
Account(
"alice");
61 auto const bob =
Account(
"bob");
62 auto const carol =
Account(
"carol");
63 auto const dan =
Account(
"dan");
64 auto const erin =
Account(
"erin");
65 auto const USDA = alice[
"USD"];
66 auto const USDB = bob[
"USD"];
67 auto const USDC = carol[
"USD"];
68 auto const USDD = dan[
"USD"];
70 auto const USD = gw[
"USD"];
73 Env env(*
this, features);
75 env.
fund(
XRP(10000), alice, bob, gw);
77 env.
trust(USD(1000), alice, bob);
78 env(
pay(gw, alice, USD(100)));
79 env(
pay(alice, bob, USD(10)),
paths(USD));
84 Env env(*
this, features);
86 env.
fund(
XRP(10000), alice, bob);
88 env(
pay(alice, bob,
XRP(100)));
94 Env env(*
this, features);
96 env.
fund(
XRP(10000), alice, bob, gw);
98 env.
trust(USD(1000), alice, bob);
99 env(
pay(gw, alice, USD(100)));
102 env(
pay(alice, bob, USD(110)),
109 Env env(*
this, features);
111 env.
fund(
XRP(10000), alice, bob, carol, dan);
113 env.
trust(USDA(10), bob);
114 env.
trust(USDB(10), carol);
115 env.
trust(USDC(10), dan);
116 env(
pay(alice, dan, USDC(10)),
paths(USDA));
125 Env env(*
this, features);
127 env.
fund(
XRP(10000), alice, bob, carol, dan);
129 env.
trust(USDA(10), bob);
130 env.
trust(USDB(10), alice, carol);
131 env.
trust(USDC(10), dan);
135 env(
pay(bob, alice, USDB(6)));
136 env(
pay(alice, dan, USDC(5)),
146 Env env(*
this, features);
148 env.
fund(
XRP(10000), alice, bob, carol, dan);
150 env.
trust(USDA(10), bob);
151 env.
trust(USDB(10), alice, carol);
152 env.
trust(USDC(10), dan);
155 env(
pay(alice, dan, USDC(5)),
165 Env env(*
this, features);
167 env.
fund(
XRP(10000), alice, bob, carol, dan, erin);
169 env.
trust(USDA(10), bob, carol);
170 env.
trust(USDB(10), dan);
171 env.
trust(USDC(10), alice, dan);
172 env.
trust(USDD(20), erin);
174 env(
rate(carol, 1.1));
177 env(
pay(carol, alice, USDC(10)));
178 env(
pay(alice, erin, USDD(5)),
189 Env env(*
this, features);
191 env.
fund(
XRP(10000), alice, bob, carol);
193 env.
trust(USDA(10), bob);
194 env.
trust(USDB(10), carol);
196 env(
pay(alice, carol, USDB(5)),
202 env(
pay(alice, carol, USDB(5)),
215 auto const alice =
Account(
"alice");
216 auto const bob =
Account(
"bob");
217 auto const carol =
Account(
"carol");
218 auto const dan =
Account(
"dan");
219 auto const USDA = alice[
"USD"];
220 auto const USDB = bob[
"USD"];
221 auto const USDC = carol[
"USD"];
222 auto const USDD = dan[
"USD"];
225 for (
auto bobDanQIn : {80, 100, 120})
226 for (
auto bobAliceQOut : {80, 100, 120})
228 Env env(*
this, features);
229 env.
fund(
XRP(10000), alice, bob, carol, dan);
233 env(
trust(carol, USDA(100)));
235 env(
pay(alice, bob, USDA(100)));
237 env(
pay(dan, carol, USDA(10)),
242 if (bobAliceQOut > bobDanQIn)
245 USDD(10.0 *
double(bobAliceQOut) /
double(bobDanQIn))));
252 for (
auto carolAliceQIn : {80, 100, 120})
254 Env env(*
this, features);
255 env.
fund(
XRP(10000), alice, bob, carol);
258 env(
trust(bob, USDA(10)));
261 env(
pay(alice, bob, USDA(10)));
263 env(
pay(bob, carol, USDA(5)),
sendmax(USDA(10)));
264 auto const effectiveQ =
265 carolAliceQIn > 100 ? 1.0 : carolAliceQIn / 100.0;
270 for (
auto bobAliceQOut : {80, 100, 120})
272 Env env(*
this, features);
273 env.
fund(
XRP(10000), alice, bob, carol);
276 env(
trust(carol, USDA(10)));
278 env(
pay(alice, bob, USDA(10)));
280 env(
pay(bob, carol, USDA(5)),
sendmax(USDA(5)));
293 auto const gw =
Account(
"gateway");
294 auto const USD = gw[
"USD"];
295 auto const BTC = gw[
"BTC"];
296 auto const EUR = gw[
"EUR"];
303 Env env(*
this, features);
305 env.
fund(
XRP(10000), alice, bob, carol, gw);
307 env.
trust(USD(1000), alice, bob, carol);
308 env.
trust(BTC(1000), alice, bob, carol);
310 env(
pay(gw, alice, BTC(50)));
311 env(
pay(gw, bob, USD(50)));
313 env(
offer(bob, BTC(50), USD(50)));
321 BEAST_EXPECT(!
isOffer(env, bob, BTC(50), USD(50)));
325 Env env(*
this, features);
327 env.
fund(
XRP(10000), alice, bob, carol, gw);
329 env.
trust(USD(1000), alice, bob, carol);
330 env.
trust(BTC(1000), alice, bob, carol);
332 env(
pay(gw, alice, BTC(50)));
333 env(
pay(gw, bob, USD(50)));
344 BEAST_EXPECT(!
isOffer(env, bob,
XRP(50), USD(50)));
345 BEAST_EXPECT(!
isOffer(env, bob, BTC(50),
XRP(50)));
349 Env env(*
this, features);
351 env.
fund(
XRP(10000), alice, bob, carol, gw);
353 env.
trust(USD(1000), alice, bob, carol);
354 env.
trust(BTC(1000), alice, bob, carol);
356 env(
pay(gw, bob, USD(50)));
366 BEAST_EXPECT(!
isOffer(env, bob,
XRP(50), USD(50)));
370 Env env(*
this, features);
372 env.
fund(
XRP(10000), alice, bob, carol, gw);
374 env.
trust(USD(1000), alice, bob, carol);
375 env.
trust(BTC(1000), alice, bob, carol);
377 env(
pay(gw, alice, USD(50)));
387 BEAST_EXPECT(!
isOffer(env, bob, USD(50),
XRP(50)));
391 Env env(*
this, features);
393 env.
fund(
XRP(10000), alice, bob, carol, gw);
395 env.
trust(USD(1000), alice, bob, carol);
396 env.
trust(BTC(1000), alice, bob, carol);
397 env.
trust(EUR(1000), alice, bob, carol);
399 env(
pay(gw, alice, BTC(60)));
400 env(
pay(gw, bob, USD(50)));
401 env(
pay(gw, bob, EUR(50)));
403 env(
offer(bob, BTC(50), USD(50)));
404 env(
offer(bob, BTC(40), EUR(50)));
405 env(
offer(bob, EUR(50), USD(50)));
408 env(
pay(bob, gw, EUR(50)));
409 BEAST_EXPECT(
isOffer(env, bob, BTC(50), USD(50)));
410 BEAST_EXPECT(
isOffer(env, bob, BTC(40), EUR(50)));
411 BEAST_EXPECT(
isOffer(env, bob, EUR(50), USD(50)));
413 env(
pay(alice, carol, USD(50)),
424 BEAST_EXPECT(!
isOffer(env, bob, BTC(50), USD(50)));
426 BEAST_EXPECT(!
isOffer(env, bob, BTC(40), EUR(50)));
428 BEAST_EXPECT(
isOffer(env, bob, EUR(50), USD(50)));
439 Env env(*
this, features);
441 env.
fund(
XRP(10000), alice, bob, carol, gw);
443 env.
trust(USD(1000), alice, bob, carol);
444 env.
trust(BTC(1000), alice, bob, carol);
445 env.
trust(EUR(1000), alice, bob, carol);
447 env(
pay(gw, alice, BTC(60)));
448 env(
pay(gw, bob, USD(60)));
449 env(
pay(gw, bob, EUR(50)));
450 env(
pay(gw, carol, EUR(1)));
452 env(
offer(bob, BTC(50), USD(50)));
453 env(
offer(bob, BTC(60), EUR(50)));
454 env(
offer(carol, BTC(1000), EUR(1)));
455 env(
offer(bob, EUR(50), USD(50)));
458 env(
pay(bob, gw, EUR(50)));
459 BEAST_EXPECT(
isOffer(env, bob, BTC(50), USD(50)));
460 BEAST_EXPECT(
isOffer(env, bob, BTC(60), EUR(50)));
461 BEAST_EXPECT(
isOffer(env, carol, BTC(1000), EUR(1)));
464 auto const flowResult = [&] {
501 BEAST_EXPECT(flowResult.removableOffers.size() == 1);
504 if (flowResult.removableOffers.empty())
507 for (
auto const& o : flowResult.removableOffers)
515 BEAST_EXPECT(
isOffer(env, bob, BTC(50), USD(50)));
516 BEAST_EXPECT(
isOffer(env, carol, BTC(1000), EUR(1)));
518 BEAST_EXPECT(!
isOffer(env, bob, BTC(60), EUR(50)));
528 Env env(*
this, features);
529 env.
fund(
XRP(10000), alice, bob, carol, gw);
532 env.
trust(USD(1000), alice, bob, carol);
533 env.
trust(EUR(1000), alice, bob, carol);
535 env(
pay(gw, alice, USD(1000)));
536 env(
pay(gw, bob, EUR(1000)));
542 bool const reducedOffersV2 = features[fixReducedOffersV2];
548 TER const expectedTER =
550 env(
pay(alice, carol, EUR(1)),
556 if (!reducedOffersV2)
564 if (BEAST_EXPECT(usdOffer))
570 to_string(usdOffer->at(sfBookDirectory));
571 bookDirStr.
erase(0, 48);
575 usdOffer->at(sfTakerGets), usdOffer->at(sfTakerPays));
581 BEAST_EXPECT(actualRate > bookRate);
594 auto const gw =
Account(
"gateway");
595 auto const USD = gw[
"USD"];
596 auto const BTC = gw[
"BTC"];
597 auto const EUR = gw[
"EUR"];
603 Env env(*
this, features);
605 env.
fund(
XRP(10000), alice, bob, gw);
608 env.
trust(USD(1000), alice, bob);
623 auto const gw =
Account(
"gateway");
624 auto const USD = gw[
"USD"];
625 auto const EUR = gw[
"EUR"];
630 Env env(*
this, features);
632 env.
fund(
XRP(10000), alice, carol, gw);
635 env.
trust(USD(1000), alice, bob, carol);
636 env.
trust(EUR(1000), alice, bob, carol);
638 env(
pay(gw, alice, EUR(50)));
639 env(
pay(gw, bob, USD(50)));
651 env(
pay(alice, carol, USD(1000000)),
657 BEAST_EXPECT(carolUSD > USD(0) && carolUSD < USD(50));
670 auto const gw =
Account(
"gateway");
671 auto const USD = gw[
"USD"];
679 env.
fund(
XRP(10000), alice, bob, carol, gw);
682 env.
trust(USD(100), alice, bob, carol);
683 env(
pay(gw, bob, USD(100)));
687 env(
pay(alice, carol, USD(100)),
701 return env.
current()->fees().accountReserve(count);
713 if (sle->getType() == ltOFFER)
714 result.push_back(sle);
731 auto const gw1 =
Account(
"gw1");
732 auto const gw2 =
Account(
"gw2");
733 auto const alice =
Account(
"alice");
734 auto const USD = gw1[
"USD"];
735 auto const EUR = gw2[
"EUR"];
737 Env env(*
this, features);
739 env.
fund(
XRP(1000000), gw1, gw2);
743 auto const f = env.
current()->fees().base;
748 env(
trust(alice, USD(2000)));
749 env(
trust(alice, EUR(2000)));
752 env(
pay(gw1, alice, USD(1)));
753 env(
pay(gw2, alice, EUR(1000)));
756 env(
offer(alice, USD(500), EUR(600)));
764 BEAST_EXPECT(aliceOffers.size() == 1);
765 for (
auto const& offerPtr : aliceOffers)
767 auto const offer = *offerPtr;
768 BEAST_EXPECT(
offer[sfLedgerEntryType] == ltOFFER);
769 BEAST_EXPECT(
offer[sfTakerGets] == EUR(600));
770 BEAST_EXPECT(
offer[sfTakerPays] == USD(500));
773 env(
pay(alice, alice, EUR(600)),
782 BEAST_EXPECT(aliceOffers.size() == 1);
783 for (
auto const& offerPtr : aliceOffers)
785 auto const offer = *offerPtr;
786 BEAST_EXPECT(
offer[sfLedgerEntryType] == ltOFFER);
787 BEAST_EXPECT(
offer[sfTakerGets] == EUR(598.8));
788 BEAST_EXPECT(
offer[sfTakerPays] == USD(499));
802 auto const gw1 =
Account(
"gw1");
803 auto const gw2 =
Account(
"gw2");
804 auto const alice =
Account(
"alice");
805 auto const USD = gw1[
"USD"];
806 auto const EUR = gw2[
"EUR"];
808 Env env(*
this, features);
810 env.
fund(
XRP(1000000), gw1, gw2);
814 auto const f = env.
current()->fees().base;
819 env(
trust(alice, USD(506)));
820 env(
trust(alice, EUR(606)));
823 env(
pay(gw1, alice, USD(500)));
824 env(
pay(gw2, alice, EUR(600)));
827 env(
offer(alice, USD(500), EUR(600)));
835 BEAST_EXPECT(aliceOffers.size() == 1);
836 for (
auto const& offerPtr : aliceOffers)
838 auto const offer = *offerPtr;
839 BEAST_EXPECT(
offer[sfLedgerEntryType] == ltOFFER);
840 BEAST_EXPECT(
offer[sfTakerGets] == EUR(600));
841 BEAST_EXPECT(
offer[sfTakerPays] == USD(500));
844 env(
pay(alice, alice, EUR(60)),
853 BEAST_EXPECT(aliceOffers.size() == 1);
854 for (
auto const& offerPtr : aliceOffers)
856 auto const offer = *offerPtr;
857 BEAST_EXPECT(
offer[sfLedgerEntryType] == ltOFFER);
858 BEAST_EXPECT(
offer[sfTakerGets] == EUR(594));
859 BEAST_EXPECT(
offer[sfTakerPays] == USD(495));
870 testcase(
"Self funded XRPEndpoint");
874 Env env(*
this, features);
876 auto const alice =
Account(
"alice");
878 auto const USD = gw[
"USD"];
880 env.
fund(
XRP(10000), alice, gw);
882 env(
trust(alice, USD(20)));
883 env(
pay(gw, alice, USD(10)));
884 env(
offer(alice,
XRP(50000), USD(10)));
888 auto const toSend = consumeOffer ? USD(10) : USD(9);
889 env(
pay(alice, alice, toSend),
903 Env env(*
this, features);
905 auto const alice =
Account(
"alice");
906 auto const bob =
Account(
"bob");
908 auto const USD = gw[
"USD"];
910 env.
fund(
XRP(100000), alice, bob, gw);
912 env(
trust(bob, USD(20)));
928 env(
pay(alice, bob, tinyAmt1),
933 BEAST_EXPECT(!
isOffer(env, gw,
XRP(0), USD(0)));
937 Env env(*
this, features);
939 auto const alice =
Account(
"alice");
940 auto const bob =
Account(
"bob");
942 auto const USD = gw[
"USD"];
944 env.
fund(
XRP(100000), alice, bob, gw);
946 env(
trust(alice, USD(20)));
961 env(
pay(gw, alice, tinyAmt1));
964 env(
pay(alice, bob,
drops(9000000000)),
969 BEAST_EXPECT(!
isOffer(env, gw, USD(0),
XRP(0)));
979 Env env(*
this, features);
981 auto const alice =
Account(
"alice");
982 auto const bob =
Account(
"bob");
984 auto const USD = gw[
"USD"];
985 auto const usdC = USD.currency;
987 env.
fund(
XRP(10000), alice, bob, gw);
989 env(
trust(alice, USD(100)));
1029 env(
pay(alice, bob,
XRP(10000)),
1040 using namespace jtx;
1042 auto const alice =
Account(
"alice");
1043 auto const bob =
Account(
"bob");
1044 auto const carol =
Account(
"carol");
1045 auto const gw =
Account(
"gw");
1049 env.
trust(gw[
"USD"](10000), alice, carol);
1051 env.
trust(gw[
"USD"](10000), bob);
1056 env(
pay(gw, alice, gw[
"USD"](1000)));
1059 env(
offer(alice, bob[
"USD"](1000),
XRP(1)));
1062 env(
pay(alice, alice,
XRP(1)),
1069 env.
trust(bob[
"USD"](10000), alice);
1070 env(
pay(bob, alice, bob[
"USD"](1000)));
1072 env(
offer(alice,
XRP(1000), bob[
"USD"](1000)));
1075 env(
pay(carol, carol, gw[
"USD"](1000)),
1076 path(~bob[
"USD"], gw),
1090 using namespace jtx;
1097 auto const alice =
Account(
"alice");
1098 auto const bob =
Account(
"bob");
1099 auto const carol =
Account(
"carol");
1100 auto const gw =
Account(
"gw");
1101 auto const USD = gw[
"USD"];
1103 env.
fund(
XRP(100000000), alice, bob, carol, gw);
1105 env.
trust(USD(10000), alice, carol);
1107 env.
trust(USD(10000), bob);
1108 env.
trust(bob[
"USD"](10000), carol);
1111 env(
pay(bob, carol, bob[
"USD"](1000)));
1112 env(
pay(gw, bob, USD(1000)));
1115 env(
offer(carol,
XRP(1), bob[
"USD"](1000)));
1118 env(
pay(alice, alice, USD(1000)),
1119 path(~bob[
"USD"], bob, gw),
1132 testcase(
"Self crossing low quality offer");
1134 using namespace jtx;
1136 Env env(*
this, features);
1138 auto const ann =
Account(
"ann");
1139 auto const gw =
Account(
"gateway");
1140 auto const CTB = gw[
"CTB"];
1147 env(
rate(gw, 1.002));
1148 env(
trust(ann, CTB(10)));
1151 env(
pay(gw, ann, CTB(2.856)));
1154 env(
offer(ann,
drops(365611702030), CTB(5.713)));
1158 env(
pay(ann, ann, CTB(0.687)),
1167 using namespace jtx;
1169 auto const alice =
Account(
"alice");
1171 Env env(*
this, features);
1176 env(
pay(alice, alice, alice[
"USD"](100)),
1177 path(~alice[
"USD"]),
1186 using namespace jtx;
1187 auto const alice =
Account(
"alice");
1188 auto const bob =
Account(
"bob");
1189 auto const gw =
Account(
"gw");
1190 auto const USD = gw[
"USD"];
1191 auto const EUR = gw[
"EUR"];
1193 for (
auto const withFix : {
true,
false})
1202 Env env(*
this, feats);
1203 env.
fund(
XRP(10000), alice, bob, gw);
1205 env.
trust(USD(1000), alice, bob);
1206 env.
trust(EUR(1000), alice, bob);
1208 env(
pay(gw, alice, USD(100)));
1209 env(
pay(gw, alice, EUR(100)));
1217 TER const expectedTer =
1219 env(
pay(alice, bob, EUR(1)),
1230 env.
fund(
XRP(10000), alice, bob, gw);
1232 env.
trust(USD(1000), alice, bob);
1233 env.
trust(EUR(1000), alice, bob);
1234 env(
pay(gw, alice, USD(100)));
1235 env(
pay(gw, alice, EUR(100)));
1242 env(
pay(alice, bob,
XRP(1)),
1251 auto const JPY = gw[
"JPY"];
1253 env.
fund(
XRP(10000), alice, bob, gw);
1255 env.
trust(USD(1000), alice, bob);
1256 env.
trust(EUR(1000), alice, bob);
1257 env.
trust(JPY(1000), alice, bob);
1259 env(
pay(gw, alice, USD(100)));
1260 env(
pay(gw, alice, EUR(100)));
1261 env(
pay(gw, alice, JPY(100)));
1270 env(
pay(alice, bob, JPY(1)),
1282 using namespace jtx;
1284 auto const alice =
Account(
"alice");
1285 auto const bob =
Account(
"bob");
1287 Env env(*
this, features);
1307 using namespace jtx;
1334 using namespace jtx;
1336 testWithFeats(sa - featureFlowCross - featurePermissionedDEX);
1348 using namespace jtx;
1366BEAST_DEFINE_TESTSUITE_PRIO(Flow, app,
ripple, 2);
1367BEAST_DEFINE_TESTSUITE_MANUAL_PRIO(Flow_manual, app,
ripple, 4);
A generic endpoint for log messages.
void pass()
Record a successful test condition.
testcase_t testcase
Memberspace for declaring test cases.
virtual OpenLedger & openLedger()=0
A currency issued by an account.
beast::Journal journal(std::string const &name)
bool modify(modify_type const &f)
Modify the open ledger.
Writable ledger view that accumulates state and tx changes.
A wrapper which makes credits unavailable to balances.
Issue const & issue() const
Discardable, editable view to a ledger.
Immutable cryptographic account descriptor.
AccountID id() const
Returns the Account ID.
A transaction testing environment.
std::uint32_t seq(Account const &account) const
Returns the next sequence number on account.
void require(Args const &... args)
Check a set of requirements.
std::shared_ptr< OpenView const > current() const
Returns the current ledger.
bool close(NetClock::time_point closeTime, std::optional< std::chrono::milliseconds > consensusDelay=std::nullopt)
Close and advance the ledger.
void trust(STAmount const &amount, Account const &account)
Establish trust lines.
void fund(bool setDefaultRipple, STAmount const &amount, Account const &account)
PrettyAmount balance(Account const &account) const
Returns the XRP balance on an account.
std::shared_ptr< SLE const > le(Account const &account) const
Return an account root.
Match the number of items in the account's owner directory.
Set Paths, SendMax on a JTx.
Sets the QualityIn on a trust JTx.
Sets the QualityOut on a trust JTx as a percentage.
Sets the SendMax on a JTx.
Set the expected result code for a JTx The test will fail if the code doesn't match.
Set a ticket sequence on a JTx.
Keylet line(AccountID const &id0, AccountID const &id1, Currency const ¤cy) noexcept
The index of a trust line for a given currency.
Keylet offer(AccountID const &id, std::uint32_t seq) noexcept
An offer from an account.
Json::Value create(Account const &account, std::uint32_t count)
Create one of more tickets.
PrettyAmount xrpMinusFee(Env const &env, std::int64_t xrpAmount)
PrettyAmount drops(Integer i)
Returns an XRP PrettyAmount, which is trivially convertible to STAmount.
Json::Value trust(Account const &account, STAmount const &amount, std::uint32_t flags)
Modify a trust line.
Json::Value pay(AccountID const &account, AccountID const &to, AnyAmount amount)
Create a payment.
Json::Value rate(Account const &account, double multiplier)
Set a transfer rate.
STPathElement IPE(Issue const &iss)
Json::Value offer(Account const &account, STAmount const &takerPays, STAmount const &takerGets, std::uint32_t flags)
Create an offer.
XRP_t const XRP
Converts to XRP Issue or STAmount.
FeatureBitset supported_amendments()
bool isOffer(jtx::Env &env, jtx::Account const &account, STAmount const &takerPays, STAmount const &takerGets)
An offer exists.
bool getNoRippleFlag(jtx::Env const &env, jtx::Account const &src, jtx::Account const &dst, Currency const &cur)
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
AccountID const & xrpAccount()
Compute AccountID from public key.
StrandResult< TInAmt, TOutAmt > flow(PaymentSandbox const &baseView, Strand const &strand, std::optional< TInAmt > const &maxIn, TOutAmt const &out, beast::Journal j)
Request out amount from a strand.
constexpr std::uint32_t tfPassive
TER offerDelete(ApplyView &view, std::shared_ptr< SLE > const &sle, beast::Journal j)
Delete an offer.
std::uint64_t getRate(STAmount const &offerOut, STAmount const &offerIn)
constexpr std::uint32_t tfPartialPayment
constexpr std::uint32_t tfNoRippleDirect
constexpr std::uint32_t tfLimitQuality
std::string to_string(base_uint< Bits, Tag > const &a)
void forEachItem(ReadView const &view, Keylet const &root, std::function< void(std::shared_ptr< SLE const > const &)> const &f)
Iterate all items in the given directory.
TERSubset< CanCvtToTER > TER
constexpr std::uint32_t tfSetNoRipple
A pair of SHAMap key and LedgerEntryType.
void run() override
Runs the suite.
void run() override
Runs the suite.
void testWithFeats(FeatureBitset features)
void testSelfPayment1(FeatureBitset features)
void testTransferRate(FeatureBitset features)
static XRPAmount reserve(jtx::Env &env, std::uint32_t count)
void testBookStep(FeatureBitset features)
void testUnfundedOffer(FeatureBitset features)
void testTicketPay(FeatureBitset features)
void testSelfFundedXRPEndpoint(bool consumeOffer, FeatureBitset features)
void testEmptyStrand(FeatureBitset features)
void testSelfPayLowQualityOffer(FeatureBitset features)
static std::vector< std::shared_ptr< SLE const > > offersOnAccount(jtx::Env &env, jtx::Account account)
void testDirectStep(FeatureBitset features)
void testLineQuality(FeatureBitset features)
void testFalseDry(FeatureBitset features)
void testSelfPayment2(FeatureBitset features)
void testReexecuteDirectStep(FeatureBitset features)
STAmount const & value() const