mirror of
https://github.com/XRPLF/rippled.git
synced 2025-12-06 17:27:55 +00:00
Update InvariantCheck, LoanManage, and LoanPay to make tests work
- Primarily updating tests, and fixing stuff that didn't work. - Tests still not expected to pass. - Add Json::Value::isMember(StaticString) so SFields can be used. - Validate more fields in ValidLoan Invariant
This commit is contained in:
@@ -395,6 +395,9 @@ public:
|
||||
/// Return true if the object has a member named key.
|
||||
bool
|
||||
isMember(std::string const& key) const;
|
||||
/// Return true if the object has a member named key.
|
||||
bool
|
||||
isMember(StaticString const& key) const;
|
||||
|
||||
/// \brief Return a list of the member names.
|
||||
///
|
||||
|
||||
@@ -573,12 +573,13 @@ LEDGER_ENTRY(ltLOAN, 0x0089, Loan, loan, ({
|
||||
// represents interest owed to the vault.
|
||||
// There are two additional values that can be computed from these:
|
||||
// - InterestOutstanding: TotalValueOutstanding - PrincipalOutstanding
|
||||
// This is the total amount of interest still pending on the loan,
|
||||
// The total amount of interest still pending on the loan,
|
||||
// independent of management fees.
|
||||
// - ManagementFeeOwed: InterestOutstanding - InterestOwed
|
||||
// This is the amount of the total interest that will be sent to the
|
||||
// The amount of the total interest that will be sent to the
|
||||
// broker as management fees.
|
||||
{sfPrincipalOutstanding, soeDEFAULT},
|
||||
{sfReferencePrincipal, soeDEFAULT},
|
||||
{sfTotalValueOutstanding, soeDEFAULT},
|
||||
{sfInterestOwed, soeDEFAULT},
|
||||
// Based on the original principal borrowed, used for
|
||||
|
||||
Reference in New Issue
Block a user