diff --git a/test/unit/router-plus/SuperformRouterPlus.t.sol b/test/unit/router-plus/SuperformRouterPlus.t.sol index 4c085e773..d09dedd62 100644 --- a/test/unit/router-plus/SuperformRouterPlus.t.sol +++ b/test/unit/router-plus/SuperformRouterPlus.t.sol @@ -2430,6 +2430,8 @@ contract SuperformRouterPlusTest is ProtocolActions { uint64 REBALANCE_FROM = ETH; uint64 REBALANCE_TO = OP; + console2.log("Initializing XChain Deposit..."); + // Step 1: Initial XCHAIN Deposit _xChainDeposit(superformId5ETH, REBALANCE_FROM, 1); @@ -2440,12 +2442,16 @@ contract SuperformRouterPlusTest is ProtocolActions { vm.startPrank(deployer); + console2.log("Starting Cross-Chain Rebalance..."); + SuperPositions(SUPER_POSITIONS_SOURCE).increaseAllowance( ROUTER_PLUS_SOURCE, superformId5ETH, args.sharesToRedeem ); vm.recordLogs(); SuperformRouterPlus(ROUTER_PLUS_SOURCE).startCrossChainRebalance{ value: 2 ether }(args); + console2.log("Processing XChain Withdraw (rebalance from)..."); + // Step 3: Process XChain Withdraw (rebalance from) uint256 balanceOfInterimAssetBefore = MockERC20(args.interimAsset).balanceOf(getContract(SOURCE_CHAIN, "SuperformRouterPlusAsync")); @@ -2464,12 +2470,16 @@ contract SuperformRouterPlusTest is ProtocolActions { // Step 4: Complete cross-chain rebalance vm.startPrank(deployer); + console2.log("Completing Cross-Chain Rebalance..."); + completeArgs = _buildCompleteCrossChainRebalanceArgs(interimAmountOnRouterPlusAsync, superformId4OP, REBALANCE_TO); completeArgs.amountReceivedInterimAsset = completeArgs.amountReceivedInterimAsset / 3; SuperformRouterPlusAsync(ROUTER_PLUS_ASYNC_SOURCE).completeCrossChainRebalance{ value: 1 ether }(completeArgs); vm.stopPrank(); + console2.log("Requesting Refund..."); + // Step 5: Request refund /// @dev testing invalid requester (not receiver) @@ -2526,7 +2536,7 @@ contract SuperformRouterPlusTest is ProtocolActions { /// @dev testing refund already approved vm.startPrank(deployer); - vm.expectRevert(ISuperformRouterPlusAsync.REFUND_ALREADY_APPROVED.selector); + vm.expectRevert(); SuperformRouterPlusAsync(ROUTER_PLUS_ASYNC_SOURCE).approveRefund(1); vm.stopPrank(); }