Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set MPT default amt to 100B #16

Merged
merged 1 commit into from
May 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/ripple/protocol/Protocol.h
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ std::size_t constexpr maxDomainLength = 256;
std::size_t constexpr maxMPTokenMetadataLength = 1024;

/** The maximum amount of MPTokenIssuance */
std::uint64_t constexpr maxMPTokenAmount = 0x7FFFFFFFFFFFFFFFull;
std::uint64_t constexpr maxMPTokenAmount = 100000000000000000ull;

/** A ledger index. */
using LedgerIndex = std::uint32_t;
Expand Down
22 changes: 11 additions & 11 deletions src/test/app/MPToken_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ class MPToken_test : public beast::unit_test::suite
Env env{*this, features};
MPTTester mptAlice(env, alice);
mptAlice.create(
{.maxAmt = 0x7FFFFFFFFFFFFFFF,
{.maxAmt = 100000000000000000ull,
.assetScale = 1,
.transferFee = 10,
.metadata = "123",
Expand Down Expand Up @@ -770,21 +770,21 @@ class MPToken_test : public beast::unit_test::suite
// the range
// Issuer fails trying to send more than the default maximum
// amount allowed
// {
// Env env{*this, features};
{
Env env{*this, features};

// MPTTester mptAlice(env, alice, {.holders = {&bob}});
MPTTester mptAlice(env, alice, {.holders = {&bob}});

// mptAlice.create({.ownerCount = 1, .holderCount = 0});
mptAlice.create({.ownerCount = 1, .holderCount = 0});

// mptAlice.authorize({.account = &bob});
mptAlice.authorize({.account = &bob});

// // issuer sends holder the default max amount allowed
// mptAlice.pay(alice, bob, maxMPTokenAmount);
// issuer sends holder the default max amount allowed
mptAlice.pay(alice, bob, maxMPTokenAmount);

// // issuer tries to exceed max amount
// mptAlice.pay(alice, bob, 1, tecMPT_MAX_AMOUNT_EXCEEDED);
// }
// issuer tries to exceed max amount
mptAlice.pay(alice, bob, 1, tecMPT_MAX_AMOUNT_EXCEEDED);
}

// Transfer fee
{
Expand Down
Loading