From efc2dc78643d5c0952cae0086674b59ca86bcc44 Mon Sep 17 00:00:00 2001 From: Mayukha Vadari Date: Thu, 11 Jun 2026 16:38:55 -0400 Subject: [PATCH] remove bad test --- src/test/app/AMMMPT_test.cpp | 48 ------------------------------------ 1 file changed, 48 deletions(-) diff --git a/src/test/app/AMMMPT_test.cpp b/src/test/app/AMMMPT_test.cpp index dda97cd9d8..e460620273 100644 --- a/src/test/app/AMMMPT_test.cpp +++ b/src/test/app/AMMMPT_test.cpp @@ -7076,54 +7076,6 @@ private: amm.ammDelete(alice_); BEAST_EXPECT(!amm.ammExists()); } - - // A tecINCOMPLETE AMM deletion can delete some zero-balance MPTokens - // before the transaction view is reset. Those deleted MPTokens must be - // reapplied after the reset so that repeated AMMDelete calls make - // forward progress. - { - Env env( - *this, - envconfig([](std::unique_ptr cfg) { - cfg->fees.referenceFee = XRPAmount(1); - return cfg; - }), - all); - - env.fund(XRP(1'000), gw_, alice_); - MPT const usd = - MPTTester({.env = env, .issuer = gw_, .holders = {alice_}, .pay = 20'000}); - MPT const btc = - MPTTester({.env = env, .issuer = gw_, .holders = {alice_}, .pay = 20'000}); - MPTTester extra({.env = env, .issuer = gw_, .fund = false}); - extra.create({.flags = tfMPTCanTransfer}); - - AMM amm(env, gw_, usd(10'000), btc(10'000)); - env.app().getOpenLedger().modify([&](OpenView& view, beast::Journal) { - Sandbox sb(&view, TapNone); - createMPToken( - sb, extra.issuanceID(), amm.ammAccount(), lsfMPTAMM | lsfMPTAuthorized); - sb.apply(view); - return true; - }); - - auto const poolUSD = keylet::mptoken(usd.issuanceID, amm.ammAccount()); - auto const poolBTC = keylet::mptoken(btc.issuanceID, amm.ammAccount()); - auto const extraToken = keylet::mptoken(extra.issuanceID(), amm.ammAccount()); - BEAST_EXPECT(env.le(poolUSD)); - BEAST_EXPECT(env.le(poolBTC)); - BEAST_EXPECT(env.le(extraToken)); - - amm.withdrawAll(gw_, std::nullopt, Ter(tecINCOMPLETE)); - BEAST_EXPECT(amm.ammExists()); - - int const remainingMPTokens = (env.le(poolUSD) ? 1 : 0) + (env.le(poolBTC) ? 1 : 0) + - (env.le(extraToken) ? 1 : 0); - BEAST_EXPECT(remainingMPTokens < 3); - - amm.ammDelete(alice_); - BEAST_EXPECT(!amm.ammExists()); - } } void