Test-only bootstrap used to install exact deployed code without calling a constructor that does not rerun during a real on-chain WASM update.
fn install(env: soroban_sdk::Env, wasm_hash: soroban_sdk::BytesN<32>)
Mint attacker-controlled legacy LP in one or more stages, redeem each stage through the exact replacement-pool WASM, then sweep all modeled PHO/USDC controlled by this contract to the test attacker account.
fn mint_redeem_sweep(
env: soroban_sdk::Env,
old_lp: soroban_sdk::Address,
pool: soroban_sdk::Address,
token_a: soroban_sdk::Address,
token_b: soroban_sdk::Address,
recipient: soroban_sdk::Address,
stages: soroban_sdk::Vec,
) -> (i128, i128)
Redeem LP already custodied by this contract, then sweep the resulting reserves and any pre-existing direct balances to the test attacker.
fn redeem_held_sweep(
env: soroban_sdk::Env,
old_lp: soroban_sdk::Address,
pool: soroban_sdk::Address,
token_a: soroban_sdk::Address,
token_b: soroban_sdk::Address,
recipient: soroban_sdk::Address,
share_amount: i128,
) -> (i128, i128)
fn sweep(
env: soroban_sdk::Env,
token_a: soroban_sdk::Address,
token_b: soroban_sdk::Address,
recipient: soroban_sdk::Address,
) -> (i128, i128)