|
xrpld
|
Helpers for constructing Batch test transactions. More...
Classes | |
| class | Inner |
| Adds an inner Batch transaction to a JTx and autofills it. More... | |
| class | Sig |
| Sets the Batch transaction signers on a JTx. More... | |
| class | Msig |
| Sets a nested multi-signature for a Batch transaction on a JTx. More... | |
Functions | |
| XRPAmount | calcBatchFee (jtx::Env const &env, uint32_t const &numSigners, uint32_t const &txns=0) |
| Calculate the expected outer Batch transaction fee. | |
| XRPAmount | calcConfidentialBatchFee (jtx::Env const &env, uint32_t const &numSigners, uint32_t const &txns=0) |
| Calculate the expected Batch fee when inner transactions are confidential MPT transactions. | |
| json::Value | outer (jtx::Account const &account, uint32_t seq, STAmount const &fee, std::uint32_t flags) |
| Build an outer Batch transaction JSON object. | |
| void | validateInnerTxn (Env &env, std::string const &batchID, std::string const &txHash, std::string const &txType, std::string const &result, std::source_location const &loc=std::source_location::current()) |
| Expect an inner Batch transaction to be recorded with the given type and result, and with ParentBatchID pointing at its outer Batch. | |
Helpers for constructing Batch test transactions.
| XRPAmount xrpl::test::jtx::batch::calcConfidentialBatchFee | ( | jtx::Env const & | env, |
| uint32_t const & | numSigners, | ||
| uint32_t const & | txns = 0 ) |
Calculate the expected Batch fee when inner transactions are confidential MPT transactions.
| env | The test environment providing ledger fee settings. |
| numSigners | Number of outer transaction signers. |
| txns | Number of confidential MPT inner transactions in the batch. |
| json::Value xrpl::test::jtx::batch::outer | ( | jtx::Account const & | account, |
| uint32_t | seq, | ||
| STAmount const & | fee, | ||
| std::uint32_t | flags ) |
Build an outer Batch transaction JSON object.
| account | The account submitting the outer Batch transaction. |
| seq | The sequence number for the outer Batch transaction. |
| fee | The fee to set on the outer Batch transaction. |
| flags | The transaction flags to set. |
| void xrpl::test::jtx::batch::validateInnerTxn | ( | Env & | env, |
| std::string const & | batchID, | ||
| std::string const & | txHash, | ||
| std::string const & | txType, | ||
| std::string const & | result, | ||
| std::source_location const & | loc = std::source_location::current() ) |
Expect an inner Batch transaction to be recorded with the given type and result, and with ParentBatchID pointing at its outer Batch.
Looks the inner transaction up with the tx RPC, so the ledger holding the batch must already be closed. Failures are reported at the caller's line.
| env | The test environment. |
| batchID | Hash of the outer Batch transaction. |
| txHash | Hash of the inner transaction. |
| txType | Expected TransactionType, e.g. "Payment". |
| result | Expected TransactionResult, e.g. "tesSUCCESS". |
| loc | Call site to report failures at. |