2025-12-18 13:07:35 +08:00
|
|
|
// SPDX-License-Identifier: MIT
|
|
|
|
|
pragma solidity ^0.8.20;
|
|
|
|
|
|
2026-02-24 16:44:47 +08:00
|
|
|
// forge script scripts/test.s.sol:TestFun \
|
|
|
|
|
// --fork-url https://data-seed-prebsc-1-s1.binance.org:8545 \
|
|
|
|
|
// -vvvvv
|
|
|
|
|
|
2025-12-18 13:07:35 +08:00
|
|
|
import "forge-std/Script.sol";
|
|
|
|
|
import "forge-std/console.sol";
|
|
|
|
|
|
|
|
|
|
contract TestFun is Script {
|
|
|
|
|
function run() external {
|
|
|
|
|
|
|
|
|
|
address from = 0xa013422A5918CD099C63c8CC35283EACa99a705d;
|
2026-03-09 10:30:50 +08:00
|
|
|
address to = 0x20B94C5E5b7361552E0548161a58696aA6FeDBd4;
|
2025-12-18 13:07:35 +08:00
|
|
|
|
2026-03-05 10:48:08 +08:00
|
|
|
bytes memory data = hex"7229bc3c0000000000000000000000000000000000000000000000000de0b6b3a7640000";
|
2025-12-18 13:07:35 +08:00
|
|
|
|
|
|
|
|
vm.startPrank(from);
|
|
|
|
|
|
|
|
|
|
(bool ok, bytes memory ret) = to.call(data);
|
|
|
|
|
|
|
|
|
|
vm.stopPrank();
|
|
|
|
|
|
|
|
|
|
console.log("Call success:", ok);
|
|
|
|
|
console.logBytes(ret);
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|